gitlab-org--gitlab-foss/db/migrate/20200526164946_create_operations_feature_flags_issues.rb

16 lines
538 B
Ruby
Raw Normal View History

# frozen_string_literal: true
class CreateOperationsFeatureFlagsIssues < ActiveRecord::Migration[6.0]
DOWNTIME = false
def change
create_table :operations_feature_flags_issues do |t|
t.references :feature_flag, index: false, foreign_key: { on_delete: :cascade, to_table: :operations_feature_flags }, null: false
t.bigint :issue_id, null: false
t.index [:feature_flag_id, :issue_id], unique: true, name: :index_ops_feature_flags_issues_on_feature_flag_id_and_issue_id
t.index :issue_id
end
end
end