pg.ddx.io  pgsql-jdbc@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Michael Bell <mikebell90@yahoo.com>
To: Oliver Jowett <oliver@opencloud.com>
Cc: pgsql-jdbc@postgresql.org
Subject: Re: Hibernate and Postgres 8.3/8.4
Date: Sat, 22 Aug 2009 00:44:40 -0700 (PDT)
Message-ID: <292862.11477.qm@web43140.mail.sp1.yahoo.com> (raw)
In-Reply-To: <4A8F9CDF.6040601@opencloud.com>
References: <57606.88414.qm@web43132.mail.sp1.yahoo.com>
	<4A8F9CDF.6040601@opencloud.com>

Aw jeez, ya nailed it. There was indeed a setString where there should be setShort. Dunno where my head was.

Thanks.



----- Original Message ----
From: Oliver Jowett <oliver@opencloud.com>
To: Michael Bell <mikebell90@yahoo.com>
Cc: pgsql-jdbc@postgresql.org
Sent: Saturday, August 22, 2009 12:23:11 AM
Subject: Re: [JDBC] Hibernate and Postgres 8.3/8.4

Michael Bell wrote:

> Caused by: org.postgresql.util.PSQLException: ERROR: operator does not exist: smallint = character varying
>   Hint: No operator matches the given name and argument type(s). You might need to add explicit type casts.
>   Position: 628

> The queries in question are all "correct" in that they use query.setXXX, where XXX is a "reasonable" thing like String, Integer, Long.....nothing fancy...

Well, from the exception, either Hibernate is doing setString() on a
parameter that is compared to a smallint, or it's doing setShort() on a
parameter that is compared to a varchar type.. so one of the two sides
is wrong.

-O



      




view thread (4+ messages)  latest in thread

Message-ID: <292862.11477.qm@web43140.mail.sp1.yahoo.com>
Permalink:  ../292862.11477.qm@web43140.mail.sp1.yahoo.com/
Also on:    postgresql.org/message-id/292862.11477.qm@web43140.mail.sp1.yahoo.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-jdbc@postgresql.org
  Cc: mikebell90@yahoo.com, oliver@opencloud.com
  Subject: Re: Hibernate and Postgres 8.3/8.4
  In-Reply-To: <292862.11477.qm@web43140.mail.sp1.yahoo.com>
  References: <57606.88414.qm@web43132.mail.sp1.yahoo.com> <4A8F9CDF.6040601@opencloud.com> <292862.11477.qm@web43140.mail.sp1.yahoo.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

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