Answers for "add column ruby on rails"

2

activerecord add column

class AddPartNumberToProducts < ActiveRecord::Migration[6.0]
  def change
    add_column :products, :part_number, :string
  end
end
Posted by: Guest on November-11-2020
0

rails add_column after

add_column :patient_allergies, :reaction_id, :integer, after: :patient_id
Posted by: Guest on July-07-2021

Code answers related to "add column ruby on rails"

Browse Popular Code Answers by Language