Hi All,
As per the documentation of ecpg, currently we support only two types of compatibility modes with ecpg and they are 1) INFORMIX and 2) INFORMIX_SE. However, it does accept any compatibility mode option that starts with INFORMIX*. For e.g. let us say, if i pass 'INFORMIX_BAD_COMPAT_MODE' as a compatibility mode, it still accepts it. [ashu@localhost bin]$ ./ecpg -C INFORMIX_BAD_COMPAT_MODE test_compat_modes.pc [ashu@localhost bin]$ Shouldn't we throw an error for this, instead of accepting it and assuming it as INFORMIX_SE mode. Thoughts? -- With Regards, Ashutosh Sharma EnterpriseDB:http://www.enterprisedb.com |
Hi,
> Shouldn't we throw an error for this, instead of accepting it and > assuming it as INFORMIX_SE mode. Thoughts? Yes, I'd say that would be better. :) Michael -- Michael Meskes Michael at Fam-Meskes dot De, Michael at Meskes dot (De|Com|Net|Org) Meskes at (Debian|Postgresql) dot Org Jabber: michael at xmpp dot meskes dot org VfL Borussia! Força Barça! Go SF 49ers! Use Debian GNU/Linux, PostgreSQL |
On Wed, Jan 10, 2018 at 5:59 PM, Michael Meskes <[hidden email]> wrote:
> Hi, > >> Shouldn't we throw an error for this, instead of accepting it and >> assuming it as INFORMIX_SE mode. Thoughts? > > Yes, I'd say that would be better. :) > Thanks Michael. Shall i submit a patch for it. Also, what about making the compatibility modes case insensitive. Currently, ecpg accepts compatibility mode only in capital letters. In case if the INFORMIX or INFORMIX_SE is entered in small or mixed type letter, ecpg throws an error. Shouldn't that be handled as well? -- With Regards, Ashutosh Sharma EnterpriseDB:http://www.enterprisedb.com > Michael > -- > Michael Meskes > Michael at Fam-Meskes dot De, Michael at Meskes dot (De|Com|Net|Org) > Meskes at (Debian|Postgresql) dot Org > Jabber: michael at xmpp dot meskes dot org > VfL Borussia! Força Barça! Go SF 49ers! Use Debian GNU/Linux, PostgreSQL |
> Thanks Michael. Shall i submit a patch for it. Also, what about
Yes, please. > making > the compatibility modes case insensitive. Currently, ecpg accepts > compatibility mode only in capital letters. In case if the INFORMIX > or > INFORMIX_SE is entered in small or mixed type letter, ecpg throws an > error. Shouldn't that be handled as well? Actually I don't mind either way. There is definitely an advantage of having it case insensitive, but then options are known to be case sensitive often enough. Michael -- Michael Meskes Michael at Fam-Meskes dot De, Michael at Meskes dot (De|Com|Net|Org) Meskes at (Debian|Postgresql) dot Org Jabber: michael at xmpp dot meskes dot org VfL Borussia! Força Barça! SF 49ers! Use Debian GNU/Linux, PostgreSQL |
On Thu, Jan 11, 2018 at 4:34 PM, Michael Meskes <[hidden email]> wrote:
>> Thanks Michael. Shall i submit a patch for it. Also, what about > > Yes, please. > Thanks. Attached are the patches 'Allow_ecpg_to_throw_error_for_wrong_compat_modes_v1' and 'Allow_ecpg_to_throw_error_for_wrong_compat_modes_v2' that fixes the reported issues. >> making >> the compatibility modes case insensitive. Currently, ecpg accepts >> compatibility mode only in capital letters. In case if the INFORMIX >> or >> INFORMIX_SE is entered in small or mixed type letter, ecpg throws an >> error. Shouldn't that be handled as well? > > Actually I don't mind either way. There is definitely an advantage of > having it case insensitive, but then options are known to be case > sensitive often enough. > embedded SQL programming languages for e.g. Pro*C accepts case insensitive options. So, why can't we make our ecpg options case insensitive as well. Thoughts? -- With Regards, Ashutosh Sharma EnterpriseDB:http://www.enterprisedb.com > Michael > -- > Michael Meskes > Michael at Fam-Meskes dot De, Michael at Meskes dot (De|Com|Net|Org) > Meskes at (Debian|Postgresql) dot Org > Jabber: michael at xmpp dot meskes dot org > VfL Borussia! Força Barça! SF 49ers! Use Debian GNU/Linux, PostgreSQL > ![]() ![]() |
> Thanks. Attached are the patches
> 'Allow_ecpg_to_throw_error_for_wrong_compat_modes_v1' and > 'Allow_ecpg_to_throw_error_for_wrong_compat_modes_v2' that fixes the > reported issues. Thanks, I just committed the case insensitive version. Michael -- Michael Meskes Michael at Fam-Meskes dot De, Michael at Meskes dot (De|Com|Net|Org) Meskes at (Debian|Postgresql) dot Org Jabber: michael at xmpp dot meskes dot org VfL Borussia! Força Barça! SF 49ers! Use Debian GNU/Linux, PostgreSQL |
On Jan 12, 2018 20:31, "Michael Meskes" <[hidden email]> wrote:
Thank you :)
|
Free forum by Nabble | Edit this page |