次の移行があります。
class CreateTariffs < ActiveRecord::Migration
def change
create_table :tariffs do |t|
t.string :name
t.decimal :amount, precision: 10, scale: 6, default: 0.0
t.timestamps
end
end
end
私の移行は次の例外で失敗します:
undefined method `sql_type' for #<ActiveRecord::ConnectionAdapters::PostgreSQLAdapter::ColumnDefinition:0x000000089a4108>/home/polygalin/.rvm/gems/ruby-2.0.0-p195/gems/activerecord-postgres-array-0.0.9/lib/activerecord-postgres-array/activerecord.rb:42:in `quote_with_array'
しかし、「金額」列のデフォルト値を削除すると、移行は成功します。小数点列のデフォルト値で移行が失敗する理由を誰でも見つけることができますか?