Skip to content

Commit

Permalink
Add primary index for tables
Browse files Browse the repository at this point in the history
  • Loading branch information
thangngoc89 committed Mar 13, 2015
1 parent 3d43289 commit e24d7b6
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ public function up()
Schema::create('users', function(Blueprint $table)
{
$table->string('id',36)->index()->unique();
$table->primary('id');
$table->string('name');
$table->string('username', 20)->nullable()->default(null)->unique();
$table->string('email')->nullable()->default(null)->unique();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ public function up()
Schema::create('gists', function(Blueprint $table)
{
$table->string('id',36)->index()->unique();
$table->primary('id');
$table->string('user_id',36)->nullable()->index();
$table->string('title');
$table->binary('content');
Expand Down

0 comments on commit e24d7b6

Please sign in to comment.