Mailing List Archive

Re: [interchange] Add support for automatic quoting of identifiers in DBI.
On 03/14/2015 11:30 AM, Peter Ajamian wrote:
> commit de7af78f372f83d082142882ea2fe48267e3efe0
> Author: Peter Ajamian <peter@pajamian.dhs.org>
> Date: Sat Mar 14 11:12:33 2015 +1300
>
> Add support for automatic quoting of identifiers in DBI.

This setting works and nicely resolves some name clash issues that arose
for a client when he upgraded mysql. I would like to eventually enable
this in catalog.cfg that comes stock with the standard demo as I think
it's a good idea to quote all identifiers in generated SQL, it avoids
all sorts of potential issues. This would mean that new catalogs would
pick up the setting but old ones would have to have it explicitly
enabled so it would not break BC.

My testing has not shown any issues, but this patch touches a lot of
code in DBI.pm, so it is very possible that I introduced a bug. Please
anyone who cares to help me test this let me know if there are any issues.


Peter

_______________________________________________
interchange-users mailing list
interchange-users@icdevgroup.org
http://www.icdevgroup.org/mailman/listinfo/interchange-users
Re: [interchange] Add support for automatic quoting of identifiers in DBI. [ In reply to ]
On 03/14/2015 11:30 AM, Peter Ajamian wrote:
> commit de7af78f372f83d082142882ea2fe48267e3efe0
> Author: Peter Ajamian <peter@pajamian.dhs.org>
> Date: Sat Mar 14 11:12:33 2015 +1300
>
> Add support for automatic quoting of identifiers in DBI.

One thing I forgot to mention in the git log is that this also adds a
quote_identifier() db method, which you can pass an identifier to and it
will return that identifier to you quoted.


Peter

_______________________________________________
interchange-users mailing list
interchange-users@icdevgroup.org
http://www.icdevgroup.org/mailman/listinfo/interchange-users
Re: [interchange] Add support for automatic quoting of identifiers in DBI. [ In reply to ]
On Sat, 14 Mar 2015, Peter wrote:

> My testing has not shown any issues, but this patch touches a lot of
> code in DBI.pm, so it is very possible that I introduced a bug.

Which databases and versions did you test it against?

> I would like to eventually enable this in catalog.cfg that comes stock
> with the standard demo as I think it's a good idea to quote all
> identifiers in generated SQL, it avoids all sorts of potential issues.

It seems reasonable to do that right now. It's not like people are making
new catalogs based on the standard demo all the time these days. Even if
they were, any new catalog should be tested so if this broke anything it
wouldn't be the end of the world.

The main thing is that it's not the default for old catalogs when someone
upgrades, which you covered.

Jon

--
Jon Jensen
End Point Corporation
https://www.endpoint.com/

_______________________________________________
interchange-users mailing list
interchange-users@icdevgroup.org
http://www.icdevgroup.org/mailman/listinfo/interchange-users
Re: [interchange] Add support for automatic quoting of identifiers in DBI. [ In reply to ]
On 03/14/2015 11:52 AM, Jon Jensen wrote:
>
> Which databases and versions did you test it against?

MySQL 5.6.23

>> I would like to eventually enable this in catalog.cfg that comes stock
>> with the standard demo as I think it's a good idea to quote all
>> identifiers in generated SQL, it avoids all sorts of potential issues.
>
> It seems reasonable to do that right now.

Ok, den.


Peter

_______________________________________________
interchange-users mailing list
interchange-users@icdevgroup.org
http://www.icdevgroup.org/mailman/listinfo/interchange-users