Skip site navigation (1) Skip section navigation (2)

Re: [Patch] JDBC3 Blob support

From: Kris Jurka <books(at)ejurka(dot)com>
To: Michael Barker <mike(at)middlesoft(dot)co(dot)uk>
Cc: acoliver(at)jboss(dot)org, pgsql-jdbc(at)postgresql(dot)org
Subject: Re: [Patch] JDBC3 Blob support
Date: 2005-03-24 19:58:11
Message-ID: (view raw, whole thread or download thread mbox)
Lists: pgsql-jdbc

On Wed, 23 Mar 2005, Michael Barker wrote:

> I will have a look at the patch over the weekend.  When I wrote the CLOB
> stuff I set it up to always use a single byte encoding, except when using
> get/setCharacterStream.  If a user required mulltibyte encodings then they
> should use the Reader/Writer combination exclusively.

AbstractJdbc2Clob.getSubString creates a String from bytes with no 
encoding specified.

AbstractJdbc3Clob.setString(long, String, int, int) gets a String's bytes 
with no encoding specified.

Even when the user wants a multibyte encoding they are stuck using the 
JVM's default encoding because the Reader/Writer's are not created with an 
encoding specified.

Yeah, it's a complicated issue.  I know you were after just the BLOB part
and I pushed you into the CLOB part.  No one else has any feedback, and no
matter what we do it won't be all that good, so maybe the smart thing to
do is just to abandon the CLOB part and just put the BLOB in by itself.  
Not to discourage you if you really are interested in the CLOB part of it,
just letting you know that it's not a prerequisite for the BLOB part to
get in.

Kris Jurka

In response to


pgsql-jdbc by date

Next:From: Vadim NasardinovDate: 2005-03-24 21:40:15
Subject: CLOB encoding (was: Re: [Patch] JDBC3 Blob support)
Previous:From: Dave CramerDate: 2005-03-24 19:50:01
Subject: Re: Unable to make a connention through jdbc

Privacy Policy | About PostgreSQL
Copyright © 1996-2017 The PostgreSQL Global Development Group