Received: from localhost (unknown [200.46.208.211]) by mail.postgresql.org (Postfix) with ESMTP id 258BF632CED for ; Sat, 22 Aug 2009 04:23:31 -0300 (ADT) Received: from mail.postgresql.org ([200.46.204.86]) by localhost (mx1.hub.org [200.46.208.211]) (amavisd-maia, port 10024) with ESMTP id 09697-05 for ; Sat, 22 Aug 2009 07:23:16 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from tremor.opencloud.co.nz (tremor.opencloud.co.nz [131.203.101.230]) by mail.postgresql.org (Postfix) with ESMTP id D947063241B for ; Sat, 22 Aug 2009 04:23:19 -0300 (ADT) Received: from 122-57-44-76.jetstream.xtra.co.nz ([122.57.44.76] helo=[192.168.1.3]) by tremor.opencloud.co.nz with esmtpsa (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.63) (envelope-from ) id 1MekwS-0005QK-Vx; Sat, 22 Aug 2009 19:23:13 +1200 Message-ID: <4A8F9CDF.6040601@opencloud.com> Date: Sat, 22 Aug 2009 19:23:11 +1200 From: Oliver Jowett User-Agent: Thunderbird 2.0.0.23 (X11/20090817) MIME-Version: 1.0 To: Michael Bell CC: pgsql-jdbc@postgresql.org Subject: Re: Hibernate and Postgres 8.3/8.4 References: <57606.88414.qm@web43132.mail.sp1.yahoo.com> In-Reply-To: <57606.88414.qm@web43132.mail.sp1.yahoo.com> X-Enigmail-Version: 0.95.7 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=-2.599 tagged_above=-10 required=5 tests=BAYES_00=-2.599 X-Spam-Level: X-Archive-Number: 200908/49 X-Sequence-Number: 19898 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