symfonydoctrinedatabase-migrationsymfony4doctrine-migrations

Symfony 4 migrations migrate failed during Execution


my problem is I want to use the

php bin/console make:migration
php bin/console doctrine:migrations:migrate

approach of Symfony 4 to update my database instead of using:

php bin/console doctrine:schema:update   --force

which works fine - to say at least.

But when I use migrations I get all the time the following error on the doctrine:migrations:migrate command:

enter image description here


Solution

  • the make:migration command apparently is meant to create the database schema, when there's none at all. (source)

    doctrine:migrations:diff is better suited to create differential migrations.

    good luck.