Forum: Ruby on Rails Quoting column names, postgres and legacy databases

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.
4ba6314bcc83565b90d4f6d84d88e32d?d=identicon&s=25 matt (Guest)
on 2006-05-25 23:53

I'm building a Rails app that intereacts with several legacy databases,
all on Postgres 7.4 and running into a few quirky problems.

I seem to have a lot of inconsistencies w/ quoting field names in
Postgres. I've written another app from scratch using Postgres and
encountered quoting trouble there too. But it seemed tied to the machine
I was serving the app from. It's now on a Windows server, without any
problems (no quoting issues and no special steps).

Currently the machine I am developing/serving on, is an Ubuntu box,
accessing a remote Postgres box (Suse). I have to \"quote\" field names
when using Model.find(). The columns are a mix of all capital, uppercase
and occasionally lowercase field names (not my doing) - would that have
anyhting to do w/ it ?

I'm really not sure where to look. Is this tied to Active Record, the
Postgres database or the Postgres drivers on the dev machine? I've
looked at the AR code and seen the quote_colum_names methods, but am not
quite sure what/where I should patch? Any help appreciated. Thanks.

This topic is locked and can not be replied to.