0

I am just getting started with symfony and am trying to build the database but I get the following error:

./symfony doctrine:build --model

Warning: array_merge(): Argument #2 is not an array in /home/nicky/symfony/symfony-1.4.8/lib/plugins/sfDoctrinePlugin/lib/task/sfDoctrineBaseTask.class.php on line 182

I have the following in schema.yml

# config/doctrine/schema.yml
JobeetCategory:
actAs: { Timestampable: ~ }
columns:
name: { type: string(255), notnull: true, unique: true }
JobeetJob:
actAs: { Timestampable: ~ }
columns:
category_id:  { type: integer, notnull: true }
type:         { type: string(255) }
company:      { type: string(255), notnull: true }
logo:         { type: string(255) }
url:          { type: string(255) }
position:     { type: string(255), notnull: true }
location:     { type: string(255), notnull: true }
description:  { type: string(4000), notnull: true }
how_to_apply: { type: string(4000), notnull: true }
token:        { type: string(255), notnull: true, unique: true }
is_public:    { type: boolean, notnull: true, default: 1 }
is_activated: { type: boolean, notnull: true, default: 0 }
email:        { type: string(255), notnull: true }
expires_at:   { type: timestamp, notnull: true }

Thanks for the help!

0

1 Answer 1

2

If that's how your file actually looks, it's not valid YAML. It's an indentation based language, and you have no indentation under your model names.

Sign up to request clarification or add additional context in comments.

2 Comments

Unable to parse file "/home/nicky/symfony/projectdirectory/config/doctrine/schema.yml": A YAML file cannot contain tabs as indentation at line 3 ( actAs: { Timestampable: ~ }).
That's correct, YAML uses spaces, not tabs. symfony-project.org/gentle-introduction/1_4/en/…

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.