Guest User

Untitled

a guest
May 21st, 2018
86
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.44 KB | None | 0 0
  1. class ChangePhoneToStringInSuppliers < ActiveRecord::Migration[5.1]
  2. def change
  3. change_column :suppliers, :phone_no_1, :string
  4. change_column :suppliers, :phone_no_2, :string
  5. end
  6. end
  7.  
  8. This migration uses change_column, which is not automatically reversible.
  9. To make the migration reversible you can either:
  10. 1. Define #up and #down methods in place of the #change method.
  11. 2. Use the #reversible method to define reversible behavior.
Add Comment
Please, Sign In to add comment