Re: "?" hstore operator broken in 9.2? - Mailing list pgsql-general

From David Johnston
Subject Re: "?" hstore operator broken in 9.2?
Date
Msg-id 00cb01cde24a$75857430$60905c90$@yahoo.com
Whole thread Raw
In response to Re: "?" hstore operator broken in 9.2?  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-general
> -----Original Message-----
> From: pgsql-general-owner@postgresql.org [mailto:pgsql-general-
> owner@postgresql.org] On Behalf Of Tom Lane
> Sent: Monday, December 24, 2012 9:34 PM
> To: David Johnston
> Cc: pgsql-general@postgresql.org
> Subject: Re: [GENERAL] "?" hstore operator broken in 9.2?
>
> "David Johnston" <polobo@yahoo.com> writes:
> > When I execute the following query:
> > SELECT 'a=>1'::hstore ? 'a'::text
>
> FWIW, works fine for me.
>
> > I get an "Input parameter count is less then expected" error message.
>
> I can't find such a message (or indeed anything mentioning "parameter
> count") anywhere in the Postgres sources.  Are you running this query bare
> in psql, or using some other client-side software?  Could the message be
> coming from the client-side code?
>
>             regards, tom lane
>

Sorry for the noise.

Indeed I use a third-party GUI and it seems that it is wanting to handle the
"?" as an input parameter placeholder as opposed to an operator.  I just lit
up psql and confirmed that test query executed as expected.

I get a "syntax error at or near $1" when I try to send a similar query
through the JDBC driver (as part of a create table column check constraint).

Given that direct function calls are available for all of the question-mark
containing operators I'll likely just stick to those for now.  I'm unsure
whether this a fundamental issue with JDBC and related escaping (or the
equivalent for the commercial GUI that I use) or if a solution is possible
(I would assume yes given psql seems to know how to deal with it) but having
now realized the situation I'll be able to course-correct in the future.

Thanks for the quick response!

Dave






pgsql-general by date:

Previous
From: John R Pierce
Date:
Subject: Re: "?" hstore operator broken in 9.2?
Next
From: Philipp Kraus
Date:
Subject: check user in group