Builder icon indicating copy to clipboard operation
Builder copied to clipboard

Fix data type issue causing foreignkey constraint

Open justcharlz opened this issue 5 years ago • 0 comments

Laravel 5.7 create_users_table migration file comes with BigIncrement for the user ID while the grafite starter pack is just increment for Create_user_meta_table hence users encounter foreign key constraint error during migrate --seed.

Illuminate\Database\QueryException : SQLSTATE[HY000]: Ge neral error: 1215 Cannot add foreign key constraint (SQL: alter table user_meta add constraint user_meta_user_id_foreign foreign key (user_id) references users (id) on delete cascade)

The latest version of Laravel 5.8 is just increment but Grafite/Starter does not work properly with it.

justcharlz avatar Apr 09 '19 17:04 justcharlz