**Migrating: 2016_01_01_000000_add_voyager_user_fields
IlluminateDatabaseQueryException
SQLSTATE[42S02]: Base table or view not found: 1146 Table ‘jaleed.users’ doesn’t exist (SQL: alter table users add avatar varchar(255) null default ‘users/default.png’ after email, add role_id bigint null after id)
at vendor/laravel/framework/src/Illuminate/Database/Connection.php:671 667| // If an exception occurs when attempting to run a query, we’ll format the error 668| // message to include the bindings with SQL, which will make this exception a 669| // lot more helpful to the developer instead of just the database’s errors. 670| catch (Exception $e)
Advertisement
Answer
YOu need first to migrate the default users
and password_resets
and then the voyagers
ones. In order to achieve this kind of order, you need to rename those 2 tables with a date previous than the ones on the others migrations, so some date previous then 2016_01_01_000000
, so something like
2015_01_01_000000_create_users_table