how to check which migration file not running in laravel 7, laravel 8, laravel 9. what is the use of laravel migration status command. "php artisan migrate:status" command in laravel. check migration file status.
Check laravel migration running status
If you want to check laravel migration file already run or not. Or check every migration status run php artisan migrate:status command. It show batch no if already run command and show blank batch for not run migrations.
php artisan migrate:status
When you run this command it show this type of output here our last two migrations not running. Now run migrate command and check again status.
+------+--------------------------------------------------------------+-------+ | Ran? | Migration | Batch | +------+--------------------------------------------------------------+-------+ | Yes | 2014_10_12_000000_create_users_table | 1 | | Yes | 2014_10_12_100000_create_password_resets_table | 1 | | Yes | 2016_06_01_000001_create_oauth_auth_codes_table | 1 | | Yes | 2016_06_01_000002_create_oauth_access_tokens_table | 1 | | Yes | 2016_06_01_000003_create_oauth_refresh_tokens_table | 1 | | Yes | 2016_06_01_000004_create_oauth_clients_table | 1 | | Yes | 2016_06_01_000005_create_oauth_personal_access_clients_table | 1 | | Yes | 2019_08_19_000000_create_failed_jobs_table | 1 | | Yes | 2019_12_14_000001_create_personal_access_tokens_table | 1 | | No | 2022_06_01_184636_create_products_table | | | No | 2022_06_02_171936_add_paid_to_users_table | | +------+--------------------------------------------------------------+-------+