Search code examples
phplaravelmigrationlaravel-5

Migration rollback by file name


I have several migration file .
I want run php artisan migrate:rollback by file name like this

2016_05_16_131054_create_contries_table.php

Solution

  • You can't specify migration to rollback. You can only rollback the last migration batch (look migrations table).

    The best you can do is to make changes in your table with new migration. Or you can save data, rollback all migrations and and migrate again.