From 4b9ac0c13303b394d6b8c879ae027d93f4e5aacd Mon Sep 17 00:00:00 2001 From: Bruno Fontes Date: Sun, 16 Sep 2018 19:29:14 -0300 Subject: [PATCH] Fixing item_user migration primary keys I had included item_id and user_id as primary keys to avoid duplications but the command line to attach I am using does not duplicate. Not only that, I got an error during migration of Multiple primary keys. --- database/migrations/2018_09_08_192152_create_items_table.php | 1 - 1 file changed, 1 deletion(-) diff --git a/database/migrations/2018_09_08_192152_create_items_table.php b/database/migrations/2018_09_08_192152_create_items_table.php index d1b83e3..17fbf98 100644 --- a/database/migrations/2018_09_08_192152_create_items_table.php +++ b/database/migrations/2018_09_08_192152_create_items_table.php @@ -26,7 +26,6 @@ class CreateItemsTable extends Migration $table->increments('id'); $table->integer('item_id'); $table->integer('user_id'); - $table->primary(['item_id', 'user_id']); }); }