pg.ddx.io  pgsql-odbc@postgresql.org mailing list archive  
help / color / mirror / Atom feed
Bug report - ODBC Driver - Error 42P18
3+ messages / 3 participants
[nested] [flat]

* Bug report - ODBC Driver - Error 42P18
@ 2014-02-28 16:20 Consolity Inc <consolity@outlook.com>
  2014-02-28 16:32 ` Re: Bug report - ODBC Driver - Error 42P18 Adrian Klaver <adrian.klaver@aklaver.com>
  2014-02-28 16:50 ` Re: Bug report - ODBC Driver - Error 42P18 Heikki Linnakangas <hlinnakangas@vmware.com>
  0 siblings, 2 replies; 3+ messages in thread

From: Consolity Inc @ 2014-02-28 16:20 UTC (permalink / raw)
  To: pgsql-odbc

The PostgreSQL ANSI ODBC driver reports 42P18 - ERROR: could not determine data type of parameter $<n>; when preparing SQL with an expression of the form:
<bound parameter> IS NULL.
This is a breaking change to existing code that depends on being able to check the NULL-ness of a parameter.
Behavior is new as of psqlODBC 09.03.0100
PostgreSQL version: 9.3.2OS: Windows

 		 	   		   		 	   		  =

^ permalink  raw  reply  [nested|flat] 3+ messages in thread

* Re: Bug report - ODBC Driver - Error 42P18
  2014-02-28 16:20 Bug report - ODBC Driver - Error 42P18 Consolity Inc <consolity@outlook.com>
@ 2014-02-28 16:32 ` Adrian Klaver <adrian.klaver@aklaver.com>
  1 sibling, 0 replies; 3+ messages in thread

From: Adrian Klaver @ 2014-02-28 16:32 UTC (permalink / raw)
  To: Consolity Inc <consolity@outlook.com>; pgsql-odbc

On 02/28/2014 08:20 AM, Consolity Inc wrote:
> The PostgreSQL ANSI ODBC driver reports 42P18 - ERROR: could not
> determine data type of parameter $<n>; when preparing SQL with an
> expression of the form:
>
> <bound parameter> IS NULL.
>
> This is a breaking change to existing code that depends on being able to
> check the NULL-ness of a parameter.
>
> Behavior is new as of psqlODBC 09.03.0100

There is a bug fix to the above version:

http://psqlodbc.projects.pgfoundry.org/docs/release.html

Not sure if that covers the error or not.

>
> PostgreSQL version: 9.3.2
> OS: Windows
>
>


-- 
Adrian Klaver
adrian.klaver@aklaver.com


-- 
Sent via pgsql-odbc mailing list (pgsql-odbc@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-odbc



^ permalink  raw  reply  [nested|flat] 3+ messages in thread

* Re: Bug report - ODBC Driver - Error 42P18
  2014-02-28 16:20 Bug report - ODBC Driver - Error 42P18 Consolity Inc <consolity@outlook.com>
@ 2014-02-28 16:50 ` Heikki Linnakangas <hlinnakangas@vmware.com>
  1 sibling, 0 replies; 3+ messages in thread

From: Heikki Linnakangas @ 2014-02-28 16:50 UTC (permalink / raw)
  To: Consolity Inc <consolity@outlook.com>; +Cc: pgsql-odbc

On 02/28/2014 06:20 PM, Consolity Inc wrote:
> The PostgreSQL ANSI ODBC driver reports 42P18 - ERROR: could not determine data type of parameter $<n>; when preparing SQL with an expression of the form:
> <bound parameter> IS NULL.
> This is a breaking change to existing code that depends on being able to check the NULL-ness of a parameter.
> Behavior is new as of psqlODBC 09.03.0100

The default for UseServerSidePrepare changed in 09.03.0100. Maybe it's 
because of that? You can try setting UseServerSidePrepare=0 to get the 
old behavior.

I would recommend modifying the query to explicitly cast the parameter, 
though. Something like "?::text IS NULL" should work.

- Heikki


-- 
Sent via pgsql-odbc mailing list (pgsql-odbc@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-odbc



^ permalink  raw  reply  [nested|flat] 3+ messages in thread


end of thread, other threads:[~2014-02-28 16:50 UTC | newest]

Thread overview: 3+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2014-02-28 16:20 Bug report - ODBC Driver - Error 42P18 Consolity Inc <consolity@outlook.com>
2014-02-28 16:32 ` Adrian Klaver <adrian.klaver@aklaver.com>
2014-02-28 16:50 ` Heikki Linnakangas <hlinnakangas@vmware.com>

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox