There is special gem that makes it possible. See
https://github.com/vprokopchuk256/mv-core for details.
With that gem you can do it in this way:
def up
change_table :table_name do
t.change :check_constraint_name, :integer, inclusion: { in: [1, 2, 3], as: :check }
end
end
Best regards,
Valeriy Prokopchuk
понеділок, 25 лютого 2013 р. 12:17:28 UTC+2 користувач Sumit Srivastava написав: