Hey all,

I am getting syntax errors in my schema.rb when I run rake
db:test:prepare.  In my migrations, I have created columns that look
like this...

add_column :prizes, :"paypal_amount", :decimal, :precision => 8, :scale
=> 2, :null=>false, :default=>0

and this works fine and creates the column correctly in the DB.  The
corresponding line in schema.rb that gets created looks like this (the
paypal_error column is shown for context)...

....
t.column "paypal_amount", :decimal, :limit => 8, :default =>
#<BigDecimal:43fac10,'0.0',4(8)>, :null => false
t.column "paypal_error", :string

Now when I run rake db:test:prepare, I get errors like the following..

C:/InstantRails-2.0-win/rails_apps/chicago/db/schema.rb:93: syntax
error, unexpe
cted ',', expecting kEND
    t.column "paypal_error", :string

It seems that the "BigDecimal" syntax that rails creates in schema.rb is
not correct, but I'm not sure if I did something wrong or if this is a
bug.  I tried recreating schema.rb running rake db:schema:dump, but it
did not help.  I'm running Rails 2.1.1 with postgres 8.3.1.

Any help is appreciated.

Thanks,
Keith
-- 
Posted via http://www.ruby-forum.com/.

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby 
on Rails: Talk" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to