diff options
author | gussan <egussan@gmail.com> | 2014-03-04 10:38:09 +0900 |
---|---|---|
committer | gussan <egussan@gmail.com> | 2014-03-04 10:38:09 +0900 |
commit | 93bc67ab114d73589c385cc83dc2dda70fa3b211 (patch) | |
tree | 7bac1508c53b3bd9253d7b821aab48a467faaea0 /db | |
parent | d0e73eeca1f4e9d460a50200518e49b3afebbac9 (diff) | |
download | gitlab-ce-93bc67ab114d73589c385cc83dc2dda70fa3b211.tar.gz |
Add index_merge_request_diffs_on_merge_request_id
Diffstat (limited to 'db')
-rw-r--r-- | db/migrate/20140304005354_add_index_merge_request_diffs_on_merge_request_id.rb | 5 | ||||
-rw-r--r-- | db/schema.rb | 4 |
2 files changed, 8 insertions, 1 deletions
diff --git a/db/migrate/20140304005354_add_index_merge_request_diffs_on_merge_request_id.rb b/db/migrate/20140304005354_add_index_merge_request_diffs_on_merge_request_id.rb new file mode 100644 index 00000000000..65d28e8cb01 --- /dev/null +++ b/db/migrate/20140304005354_add_index_merge_request_diffs_on_merge_request_id.rb @@ -0,0 +1,5 @@ +class AddIndexMergeRequestDiffsOnMergeRequestId < ActiveRecord::Migration + def change + add_index :merge_request_diffs, :merge_request_id, unique: true + end +end diff --git a/db/schema.rb b/db/schema.rb index 4f6d942eeb3..9f1de4d2120 100644 --- a/db/schema.rb +++ b/db/schema.rb @@ -11,7 +11,7 @@ # # It's strongly recommended that you check this file into your version control system. -ActiveRecord::Schema.define(version: 20140214102325) do +ActiveRecord::Schema.define(version: 20140304005354) do create_table "broadcast_messages", force: true do |t| t.text "message", null: false @@ -114,6 +114,8 @@ ActiveRecord::Schema.define(version: 20140214102325) do t.datetime "updated_at" end + add_index "merge_request_diffs", ["merge_request_id"], name: "index_merge_request_diffs_on_merge_request_id", unique: true, using: :btree + create_table "merge_requests", force: true do |t| t.string "target_branch", null: false t.string "source_branch", null: false |