Sha256: 4d9b2a84e8cabeb53a10432c7f4658e88a1a62db067c73cf771e5cb52a648bd7
Contents?: true
Size: 1.09 KB
Versions: 177
Compression:
Stored size: 1.09 KB
Contents
class AddColumnsToPatients < ActiveRecord::Migration[5.0] def change reversible do |direction| direction.up { change_column :patients, :local_patient_id, :string, null: true } direction.down { change_column :patients, :local_patient_id, :string, null: false } end add_column :patients, :local_patient_id_2, :string add_column :patients, :local_patient_id_3, :string add_column :patients, :local_patient_id_4, :string add_column :patients, :local_patient_id_5, :string add_column :patients, :external_patient_id, :string add_index :patients, :local_patient_id add_index :patients, :local_patient_id_2 add_index :patients, :local_patient_id_3 add_index :patients, :local_patient_id_4 add_index :patients, :local_patient_id_5 add_index :patients, :external_patient_id # add_column :patients, :local_patient_ids, :text, array: true, default: [] # add_index :patients, :local_patient_ids, using: :gin # enable_extension "hstore" # add_column :patients, :local_ids, :hstore # add_index :patients, :local_ids, using: :gin end end
Version data entries
177 entries across 177 versions & 1 rubygems