How can I do a migration in laravel 5.5?

It sounds like you’re using a database that already has a users table, but no migration table. Therefore, when you run the migration, it’s attempting to create the users table again.

There are two things you can try:

1) Try setting up a new (empty) database in MySQL and update the settings in your .env file to point to this new DB. Run php artisan migrate and see if your migrations are correctly applied.

2) Using your existing database, delete / drop all tables (make a backup of the data if you want to retain it), and then run php artisan migrate and see if that fixes the issue.

Leave a Comment