Received: from maia.hub.org (maia-5.hub.org [200.46.204.29]) by mail.postgresql.org (Postfix) with ESMTP id 4920F133798E for ; Fri, 24 Sep 2010 19:14:07 -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 93475-10 for ; Fri, 24 Sep 2010 22:14:01 +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 A9DD81336FA7 for ; Fri, 24 Sep 2010 19:13:59 -0300 (ADT) Received: from sam.nabble.com ([192.168.236.26]) by kuber.nabble.com with esmtp (Exim 4.63) (envelope-from ) id 1OzGWl-0004qO-2Z for pgsql-bugs@postgresql.org; Fri, 24 Sep 2010 15:13:59 -0700 Date: Fri, 24 Sep 2010 15:13:59 -0700 (PDT) From: stagirus To: pgsql-bugs@postgresql.org Message-ID: <1285366439070-2853322.post@n5.nabble.com> In-Reply-To: <4C9CD5FD0200002500035D22@gw.wicourts.gov> References: <1285364037415-2853280.post@n5.nabble.com> <4C9CD5FD0200002500035D22@gw.wicourts.gov> Subject: Re: 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=-5 required=5 tests=BAYES_00=-1.9, URI_HEX=1.122 X-Spam-Level: X-Archive-Number: 201009/256 X-Sequence-Number: 28220 Thank you for your quick response. As I stated above, we directly do not call any JDBC API, not any more. It is all done by Hibernate OR mapping. The above solution (Hibernate mapping) worked fine with Oracle JDBC drivers, for a long time. I believe Hibernate might be mapping, or calling the appropriate JDBC API, for boolean fields. I guess it would be set/getBoolean methods, right? If I were to guess, Oracle JDBC driver happily takes Java true/false as boolean values and maps to integer columns (0 or 1). Whereas PostgresQL might be expecting 'f' or 't' for boolean values for obvious reasons. My impression is it is the way PostgresQL (JDBC) team views the boolean values should function. As all other religions - it is just a matter of perspective. We are just your users, BTW, the users perspective is very helpful it not powerful. Am I making sense? If you need, I will get the exception report from my developer. Thank you again. -- View this message in context: http://postgresql.1045698.n5.nabble.com/Mapping-Hibernate-boolean-to-smallint-Postgresql-tp2853280p2853322.html Sent from the PostgreSQL - bugs mailing list archive at Nabble.com.