class ChangeTeamCityChainedProjectstoRestProjects < ActiveRecord::Migration
  def up
    execute <<-SQL
        UPDATE projects set type = "TeamCityRestProject" where type = "TeamCityChainedProject";
    SQL
  end

  def down

  end
end

class ChangeTeamCityChainedProjectstoRestProjects < ActiveRecord::Migration
  Project = Class.new ActiveRecord::Base do
    self.inheritance_column = nil
  end

  def up
    Project.where(type: "TeamCityChainedProject").update_all(type: "TeamCityRestProject")
  end

  def down

  end
end

Fix migration so it will run on pg and mysql
Fix migration so it will run on pg and mysql
