-
Roll back all the migrations (or start with a fresh database);
-
Change the dates that form the first part of the migration filenames so they’re in the order you want (eg. for
2014_06_24_134109_update_database.php, the date & time is 2014-06-24, 13:41:09); -
Run the migrations again.
With respect to your comment about foreign keys… I’m not sure that the problem is with Laravel. More likely, it’s just MySQL.
I avoid foreign keys because once you get a moderately complicated set of relations, you start to run into problems with database consistency like you’re seeing – it’s hard for the server to figure out what order to create the tables & relationships in, and it starts to cause difficulties with things like dump files (for backups).