[Jruby-extras-devel] Problem with activerecord-jdbc-adapter 0.7.1 and Oracle?

Schultz, Darcy L. Darcy.L.Schultz at encana.com
Wed Jan 9 16:57:34 EST 2008

I'm using:
Java 6
JRuby 1.0.3
Rails 2.0.2
activerecord-jdbc-adapter 0.7.1
When I try to persist an object to an Oracle table I get the following:
Loading development environment (Rails 2.0.2)
>> Person.find :all
>> => []
p = Person.new
>> => #<Person id: nil, name: nil>
p.name = 'Darcy'
=> "Darcy"
>> p.save
ActiveRecord::StatementInvalid: ActiveRecord::ActiveRecordError:
ORA-01006: bind variable does not exist
: INSERT INTO people (name) VALUES('Darcy')
ord/transactions.rb:129:in `rollback_active_record_state!'
ord/transactions.rb:108:in `save_with_transactions'
        from (irb):4:in `binding'
        from D:/jruby-1.0.3/lib/ruby/1.8/irb.rb:150:in `eval_input'
        from D:/jruby-1.0.3/lib/ruby/1.8/irb.rb:70:in `signal_status'
        from D:/jruby-1.0.3/lib/ruby/1.8/irb.rb:147:in `eval_input'
        from D:/jruby-1.0.3/lib/ruby/1.8/irb.rb:70:in
        from D:/jruby-1.0.3/lib/ruby/1.8/irb.rb:146:in `loop'
        from D:/jruby-1.0.3/lib/ruby/1.8/irb.rb:146:in `catch'
        from D:/jruby-1.0.3/lib/ruby/1.8/irb.rb:146:in `eval_input'
        from D:/jruby-1.0.3/lib/ruby/1.8/irb.rb:70:in `start'
        from :1:in `catch'
        from D:/jruby-1.0.3/lib/ruby/1.8/irb.rb:69:in `start'
        from :1
>> p.id = 1
>> => 1
=> true
>> Person.find :all
=> [#<Person id: 1, name: "Darcy">]
Is there anything else I need to do to work with Oracle?

This email communication and any files transmitted with it may contain confidential and or proprietary information and is provided for the use of the intended recipient only. Any review, retransmission or dissemination of this information by anyone other than the intended recipient is prohibited.  If you receive this email in error, please contact the sender and delete this communication and any copies immediately. Thank you. 

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://rubyforge.org/pipermail/jruby-extras-devel/attachments/20080109/bf2fb79f/attachment.html 

More information about the Jruby-extras-devel mailing list