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

20170222143603_rename_gl_project_id_to_project_id.rb « migrate « db - gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 7c19d471557811cccd05bcb9c388710cad7a518f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
class RenameGlProjectIdToProjectId < ActiveRecord::Migration
  include Gitlab::Database::MigrationHelpers

  DOWNTIME = true
  DOWNTIME_REASON = 'Renaming an actively used column.'

  def change
    rename_column :ci_builds, :gl_project_id, :project_id
    rename_column :ci_commits, :gl_project_id, :project_id
    rename_column :ci_runner_projects, :gl_project_id, :project_id
    rename_column :ci_triggers, :gl_project_id, :project_id
    rename_column :ci_variables, :gl_project_id, :project_id
  end
end