TheBAST
TheBAST

Reputation: 2736

Laravel migration error when creating a new migration with same name that I deleted

Why do laravel has this error failed to open stream: no such file or directory.

I just deleted the 'makers' table and make a new one using php artisan make:migration command but now it has that error. Please help me

Upvotes: 1

Views: 287

Answers (2)

AddWeb Solution Pvt Ltd
AddWeb Solution Pvt Ltd

Reputation: 21681

I think you forgot to delete migration from migrations table. For check run below given mysql query, If you found, remove it and try.

SELECT * FROM `migrations` WHERE migration = 'YOURMIGRATIONNAME';

This should work for you..!

Upvotes: 0

Amit Gupta
Amit Gupta

Reputation: 17688

Make sure to run composer dump-autoload before running the migration.

In your terminal run:

composer dump-autoload

Upvotes: 3

Related Questions