@jasen
To run database migrations in Symfony, you need to follow these steps:
1
|
php bin/console make:migration |
This will create a new migration file in your project's migrations directory.
1
|
php bin/console doctrine:migrations:migrate |
This will execute all the pending migrations in your project's migrations directory.
Note: Before running the migration, make sure to configure your database connection in the .env file, and also make sure that your database schema is up to date with your current entities by running:
1
|
php bin/console doctrine:schema:update --force |
This will ensure that your migrations can be applied successfully.