Down Migration exception in ActiveRecord-JDBC on JavaDB
-------------------------------------------------------
Key: JRUBY-1250
URL: http://jira.codehaus.org/browse/JRUBY-1250
Project: JRuby
Issue Type: Bug
Components: ActiveRecord-JDBC
Affects Versions: JRuby 1.0.0
Environment: ruby 1.8.5 (2007-07-27 rev 3876) [x86-jruby1.1] (build
4068)
java 1.6.0_02
Reporter: Doug Donohoe
Assignee: Thomas E Enebo
Attachments: 001_create_products.rb, 002_add_price.rb, product.rb
Running through the depot sample application in "Agile Web Development with
Rails" on Derby (JavaDB).
Sequence of events:
* Migrate to version 2
* Added one record (using admin scaffold)
* Migrate to version 0
Got this error
{code}
(in C:/home/dev/ruby/depot)
== AddPrice: reverting ========================================================
-- remove_column(:products, :price)
rake aborted!
NativeException: java.sql.SQLSyntaxErrorException: Columns of type 'DECIMAL'
cannot hold values of type 'CHAR'. :
INSERT INTO altered_products (id,title,description,image_url,price) VALUES (1,
'Test', CAST('Test' AS CLOB), 'test.jpg', '10.00')
{code}
Are the tick-quotes around the 10.00 supposed to be there?
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe from this list please visit:
http://xircles.codehaus.org/manage_email