[CDBI] column case sensitivity (Pg)

Matt S Trout dbix-class at trout.me.uk
Tue Aug 22 14:32:06 BST 2006


Erik Sluiters wrote:
> Hi all,
> The postgres database i work on unfortunatly makes use of case sensitive 
> column names. It was a wrong database design decision (not by me thankfully), 
> i wish i could just change column names but it just breaks too much in the 
> interface to do. 
> I'm really impressed by the functionality of ClassDBI but unfortunatly 
> ClassDBI doesn't work with column names with uppercases in it. I took a peek 
> at the ClassDBI code and found that it is quite trivial to make it work with 
> case sensitive column names, basically i just removed all conversions to 
> lowercase.
> I've listed the changes below, unless there is a good reason to have ClassDBI 
> only work with lowercase column names maybe this could be incorporated in the 
> main branch of ClassDBI? That way anyone can have a lousily designed database 
> and still use ClassDBI...

That wouldn't be backwards compatible.

You'd probably be better switching to DBIx::Class, which already supports this.

-- 
      Matt S Trout       Offering custom development, consultancy and support
   Technical Director    contracts for Catalyst, DBIx::Class and BAST. Contact
Shadowcat Systems Ltd.  mst (at) shadowcatsystems.co.uk for more information

+ Help us build a better perl ORM: http://dbix-class.shadowcatsystems.co.uk/ +



More information about the ClassDBI mailing list