From: Matt Magoffin <postgresql.org@msqr.us>
To: pgsql-jdbc@postgresql.org
Subject: Statement setNull for Types.CLOB
Date: Fri, 18 Feb 2005 09:41:17 -0800 (PST)
Message-ID: <49924.192.168.1.1.1108748477.squirrel@192.168.1.1> (raw)
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.
I can easily change the Hibernate mapping to "string", which would change
the SQL type passed to setNull() to Types.VARCHAR, but I was wondering if
Types.CLOB should be a supported value in the setNull() JDBC method?
I realize it might not be correct to think of the PostgreSQL text type as
a CLOB, so I just wanted some insight on this issue if possible.
Thanks,
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: postgresql.org@msqr.us
Subject: Re: Statement setNull for Types.CLOB
In-Reply-To: <49924.192.168.1.1.1108748477.squirrel@192.168.1.1>
References: <49924.192.168.1.1.1108748477.squirrel@192.168.1.1>
* 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