Welcome to mirror list, hosted at ThFree Co, Russian Federation.

20140416074002_add_index_on_iid.rb « migrate « db - gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: cbd09082781171913a134009e3ad0d67d0200ffc (plain)
1
2
3
4
5
6
7
class AddIndexOnIid < ActiveRecord::Migration
  def change
    add_index :issues, [:project_id, :iid], unique: true
    add_index :merge_requests, [:target_project_id, :iid], unique: true
    add_index :milestones, [:project_id, :iid], unique: true
  end
end