On page 221, I attempted to build the Doctrine model from schema.yml (in Symfony CLI) using the command
symfony doctrine:build --all. I receive the following error for which I have been unable to resolve.
Code:
Invalid schema element named "first_name" at path "columns"
After correcting the typos, here is the schema.yml content
Code:
Addresses:
actAs:
Timestampable:
created:
name: created
type: timestamp
format: Y-m-d H:i:s
notnull: false
updated:
name: updated
type: timestamp
format: Y-m-d H:i:s
notnull: false
columns:
first_name: { type: string(40), notnull: false }
last_name: { type: string(40), notnull: false }
email: { type: string(40), notnull: false }
phone: { type: integer(40), notnull: false }
description: { type: object, notnull: false }
options:
type: MYISAM
collate: utf8_general_ci
The YAML temp file Doctrine creates looks like this:
Code:
Addresses:
actAs:
Timestampable: null
created:
name: created
type: timestamp
format: 'Y-m-d H:i:s'
notnull: false
updated:
name: updated
type: timestamp
format: 'Y-m-d H:i:s'
notnull: false
columns:
first_name:
type: string(40)
notnull: false
last_name:
type: string(40)
notnull: false
email:
type: string(40)
notnull: false
phone:
type: integer(40)
notnull: false
description:
type: object
notnull: false
options:
type: MYISAM
collate: utf8_general_ci
I don't understand what the problem is. Please advise.