[jifty-devel] Perhaps another bug :)

Jesse Vincent jesse at bestpractical.com
Wed Mar 22 11:03:50 EST 2006



> There is easier solution. Many DBs (I hope all) allow you to quote
> indentifiers (table names, columns, schema...) in your queries. I sent
> such for DBIx::SB and it was applied, but then was reverted because of
> Pg which makes quoted indentifiers case-sensetive and this broke RT.

I'd remembered that it broke things, but my memory was that it broke
things worse than that. so.  Yes. Please send the patch for Jifty::DBI
;)


> We could apply such change in JDBI, I find case-sensetivity easier to
> follow requirement then reserved word, because if you don't know words
> of all DBs then your app is not portable, as I remember I wrote that
> patch to port RT on Firebird because RT uses identifiers that are
> reserved in Firebird.
> 
> On 3/22/06, Marc Beyer <djhumbucker at tirwhan.org> wrote:
> > Jesse Vincent :
> >
> > > The previous poster was correct. Jifty::DBI doesn't go to lengths to
> > > stop you from using an SQL reserved word for a column name, which means
> > > it might blow up. Should we be trying to protect you from yourself with
> > > a list of reserved words?
> >
> > Maybe there could be a configuration (or installation) option for
> > prepending all created tables and columns with a string? E.g.
> >
> > Database:
> >   Prefix: ji_
> >
> > would create and use the column "ji_order" in the database when
> > specified as "order" in the Schema class.
> >
> > I'm not sure what kind of runtime penalty that would entail, but it
> > would give users who don't want to care about hitting a reserved word an
> > easy workaround. Might also be useful if you're mixing Jifty- and
> > non-Jifty tables in a single database.
> >
> > Cheers,
> >
> > Marc
> > _______________________________________________
> > jifty-devel mailing list
> > jifty-devel at lists.jifty.org
> > http://lists.jifty.org/cgi-bin/mailman/listinfo/jifty-devel
> >
> 
> 
> --
> Best regards, Ruslan.

> _______________________________________________
> jifty-devel mailing list
> jifty-devel at lists.jifty.org
> http://lists.jifty.org/cgi-bin/mailman/listinfo/jifty-devel


-- 


More information about the jifty-devel mailing list