Commit b288faf4 authored by dfrazao-gitlab's avatar dfrazao-gitlab

Inconsistent schema - index

Add index_design_management_versions_on_author_id index

Changelog: fixed

Relates to https://gitlab.com/gitlab-org/gitlab/-/issues/349549
parent 82253cc6
# frozen_string_literal: true
class AddAuthorIndexToDesignManagementVersions < Gitlab::Database::Migration[1.0]
TABLE = :design_management_versions
INDEX_NAME = 'index_design_management_versions_on_author_id'
disable_ddl_transaction!
def up
add_concurrent_index TABLE, :author_id, where: 'author_id IS NOT NULL', name: INDEX_NAME
end
def down
remove_concurrent_index TABLE, :author_id, name: INDEX_NAME
end
end
3fa0d827ab8051d270a13ae5facb1560a87f9f4fef81368b9fbb5d6291948721
\ No newline at end of file
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment