debian-mirror-gitlab/db/migrate/20160615191922_set_missing_stage_on_ci_builds.rb

10 lines
246 B
Ruby
Raw Normal View History

2016-06-22 15:30:34 +05:30
class SetMissingStageOnCiBuilds < ActiveRecord::Migration
include Gitlab::Database::MigrationHelpers
def up
update_column_in_batches(:ci_builds, :stage, :test) do |table, query|
query.where(table[:stage].eq(nil))
end
end
end