2014-10-28 149 views
0

我在Laravel中創建了一些遷移文件。當我在終端輸入php artisan migrate 時,一切都很順利。如果我想回滾所有的遷移,I型php artian migrate:refresh,我得到一個錯誤:Laravel遷移重置失敗

[ErrorException]                
include(/Applications/XAMPP/xamppfiles/htdocs/api-dashboardv2/app/database/ 
migrations/2014_10_03_113254_create_groups_user_table.php): failed to open 
stream: No such file or directory. 

如果該文件是2014_10_03_113254_create_groups_user_table.php但我把它改爲2014_10_03_113254_create_group_user_table.php(無「S」按組)的名稱。

我更改了文件名後,手動刪除了我的數據庫,並使用遷移文件再次創建了表格。

我不明白爲什麼我仍然得到這個錯誤。

+1

你嘗試過'composer dump'嗎?可能需要重新加載文件 – Laurence 2014-10-28 08:05:56

+1

你是否刪除了包括遷移表在內的整個表? – Laurence 2014-10-28 08:06:21

+0

是的,我刪除了整個數據庫,包括遷移表。但是,作曲家轉儲確實奏效!謝謝;) – Marten 2014-10-28 08:11:03

回答

1

你試過composer dump?自您更改遷移文件後,可能需要重新加載文件。