X-Original-To: pgsql-jdbc-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id 69F0B8B9B8A for ; Fri, 18 Feb 2005 20:10:33 +0000 (GMT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 36860-04 for ; Fri, 18 Feb 2005 20:10:20 +0000 (GMT) Received: from mail63.csoft.net (leary3.csoft.net [63.111.22.74]) by svr1.postgresql.org (Postfix) with SMTP id 64C4D8BA283 for ; Fri, 18 Feb 2005 20:10:20 +0000 (GMT) Received: (qmail 19652 invoked by uid 1112); 18 Feb 2005 20:10:19 -0000 Date: Fri, 18 Feb 2005 15:10:19 -0500 (EST) From: Kris Jurka X-X-Sender: books@leary.csoft.net To: Matt Magoffin Cc: pgsql-jdbc@postgresql.org Subject: Re: Statement setNull for Types.CLOB In-Reply-To: <49924.192.168.1.1.1108748477.squirrel@192.168.1.1> Message-ID: References: <49924.192.168.1.1.1108748477.squirrel@192.168.1.1> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.012 tagged_above=0 required=5 tests=AWL X-Spam-Level: X-Archive-Number: 200502/126 X-Sequence-Number: 12306 On Fri, 18 Feb 2005, Matt Magoffin wrote: > Hello, I'm using PostgreSQL 8 and the 310 build of the 8.0 JDBC3 driver > with Hibernate. For 'text' columns in my database, I had mapped them to > the Hibernate "text" type. When attempting to set the value of a text > column to 'null' via a PreparedStatement Hibernate calls setNull() passing > the Types.CLOB as the SQL type. The Postgres driver is throwing an > exception, however, saying that type is unknown. > This problem was just reported for bytea/BLOB here: http://archives.postgresql.org/pgsql-jdbc/2005-02/msg00115.php The same situation applies, I've fixed the setNull call to do something, but again CLOB really maps to the oid datatype in pg, not text. Kris Jurka