When I set up my migrations, do I have to include the relationships each table has there? Or is it fine if I just establish the relationship in the model?
Ex:
create_table :accounts do |t|
t.belongs_to :supplier, index: true
t.string :account_number
t.timestamps null: false
end
Hey Neel- quick question:
When I set up my migrations, do I have to include the relationships each table has there? Or is it fine if I just establish the relationship in the model? Ex: create_table :accounts do |t| t.belongs_to :supplier, index: true t.string :account_number t.timestamps null: false end