Remove not-null constraint on lock_version column if it exists

Closes #21678
This commit is contained in:
Stan Hu 2016-08-30 16:29:11 -07:00
parent 88295e0742
commit cc3b6f12cc
2 changed files with 14 additions and 1 deletions

View File

@ -0,0 +1,13 @@
class ChangeLockVersionNotNull < ActiveRecord::Migration
include Gitlab::Database::MigrationHelpers
DOWNTIME = false
def up
change_column_null :issues, :lock_version, true
change_column_null :merge_requests, :lock_version, true
end
def down
end
end

View File

@ -11,7 +11,7 @@
#
# It's strongly recommended that you check this file into your version control system.
ActiveRecord::Schema.define(version: 20160827011312) do
ActiveRecord::Schema.define(version: 20160830232601) do
# These are extensions that must be enabled in order to support this database
enable_extension "plpgsql"