Received: from maia.hub.org (maia-5.hub.org [200.46.204.29]) by mail.postgresql.org (Postfix) with ESMTP id 94D4E1337B4C for ; Mon, 27 Sep 2010 14:09:01 -0300 (ADT) Received: from mail.postgresql.org ([200.46.204.86]) by maia.hub.org (mx1.hub.org [200.46.204.29]) (amavisd-maia, port 10024) with ESMTP id 80220-02 for ; Mon, 27 Sep 2010 17:08:54 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from kuber.nabble.com (kuber.nabble.com [216.139.236.158]) by mail.postgresql.org (Postfix) with ESMTP id 2C46E1337B51 for ; Mon, 27 Sep 2010 14:08:54 -0300 (ADT) Received: from sam.nabble.com ([192.168.236.26]) by kuber.nabble.com with esmtp (Exim 4.63) (envelope-from ) id 1P0HC8-0002Zs-BF for pgsql-jdbc@postgresql.org; Mon, 27 Sep 2010 10:08:52 -0700 Date: Mon, 27 Sep 2010 10:08:52 -0700 (PDT) From: stagirus To: pgsql-jdbc@postgresql.org Message-ID: <1285607332343-2855614.post@n5.nabble.com> In-Reply-To: <4CA0805B0200002500035F43@gw.wicourts.gov> References: <4CA064B50200002500035F29@gw.wicourts.gov> <1285601721239-2855475.post@n5.nabble.com> <4CA0805B0200002500035F43@gw.wicourts.gov> Subject: Re: [BUGS] Mapping Hibernate boolean to smallint(Postgresql) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=-0.778 tagged_above=-10 required=5 tests=BAYES_00=-1.9, URI_HEX=1.122 X-Spam-Level: X-Archive-Number: 201009/54 X-Sequence-Number: 20924 Kevin's response above seems to be very promising. From your comments/observations, are you saying that there could be some coding issues regarding these conversions between boolean and integers? Reg your question of "What kinds of values do you see in the SMALLINT column when you set a TRUE into a SMALLINT column? 1? -1?" : Nothing. Because it fails before any inserts or updates happen. We discussed the error above. Because I have not worked with the internals of Hibernate/JDBC drivers, I cannot definitively state if Hibernate is calling setters and getters (setBoolean) using prepared statements or directly executes INSERT/UPDATE statements. Anything is possible. Thanks. -- View this message in context: http://postgresql.1045698.n5.nabble.com/Re-BUGS-Mapping-Hibernate-boolean-to-smallint-Postgresql-tp2855367p2855614.html Sent from the PostgreSQL - jdbc mailing list archive at Nabble.com.