In Rails Migration scripts if a table column is defined as
t.column :my_decimal_column, :decimal, :precision =>8, :scale =>2, :default =>0.00, it would result with a column decimal(10,0) in Mysql db. The problem is with the current stable rails. With Edgerails, it will work.
Visit EdgeRails at http://wiki.rubyonrails.com/rails/pages/EdgeRails
A work aroung for this could be, in your migration script use:
execute "alter table my_table modify column my_decimal_column decimal(8,2)" instead.
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment