Sha256: 9c3facd451687b6b4b49415dc8f09de43591e8975a136a4dbce2f78ed0750849
Contents?: true
Size: 366 Bytes
Versions: 2
Compression:
Stored size: 366 Bytes
Contents
class MoveConditionalIdsUsedForChoiceFieldToTheirOwnColumn < ActiveRecord::Migration def change add_column Fe::Element.table_name, :choice_field_id, :integer Fe::Element.reset_column_information Fe::Element.where(conditional_type: nil).where("conditional_id is not null").update_all("choice_field_id = conditional_id, conditional_id = null") end end
Version data entries
2 entries across 2 versions & 1 rubygems