Forum: Ruby on Rails ActiveRecord adding quotes where it should not using JDBC Oracle Driver

Announcement (2017-05-07): is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see and for other Rails- und Ruby-related community platforms.
DavidPaquet (Guest)
on 2008-10-09 04:03
(Received via mailing list)
Hi everyone,

So here is my problem :

I'm using the Oracle JDBC Driver (with JRuby) to talk to a legacy
database.  I also use set_table_name directive since my model doesn't
have the same name as my table.

class Person < ActiveRecord::Base
    set_table_name 'BOTS.USERS'

In the console, if I try Person.find(1) I get an error saying that the
table doesn't exit.  The query generated is  : SELECT * FROM

The thing is that this is not valid, it should be :


How could I fix this ?
This topic is locked and can not be replied to.