Re: Postgres PooledConnection... - Mailing list pgsql-jdbc

From Barry Lind
Subject Re: Postgres PooledConnection...
Date
Msg-id 3E68FBCC.1020408@xythos.com
Whole thread Raw
In response to Re: Postgres PooledConnection...  (Dirk Bromberg <bromberg@tzi.de>)
List pgsql-jdbc
Dirk,

This is a bug in the database.  It was reported on the hackers mail list
a week or two ago by Peter Eisentraut.  The problem is that when the
client_encoding parameter is set the server is doing character set
conversions on the bytea data (which since it is binary data is clearly
the wrong thing to do).  The reason you are seeing this while using the
7.3 driver, but not the 7.2 driver, is because the 7.3 driver uses the
client_encoding feature of the server to do the character set
translation where the 7.2 driver does not.  This change was done because
the java character set conversion is relatively slow (especially in 1.1,
1.2 and 1.3 jvms) as compared to the servers implementation.

I don't know if a fix for this problem has been made yet.

thanks,
--Barry


Dirk Bromberg wrote:
> On Thu, 2003-03-06 at 16:55, Aaron Mulder wrote:
>
>>    There was a patch for this.  If I recall correctly it was checked
>>in to CVS HEAD but not one of the relvant branches.  What version are you
>>using, and are you able to build from source and see if that solves the
>>problem?
>>
>>Aaron
>
>
> I've used the pg73jdbc3.jar from the download page.
> sorry I can't compile and see. We've switched to PreparedStmnts with
> set/getBytes and bytea Cols. The problem there is the Bug in the 73.jar
> (see the mails on the list) so we now use the 72.jar and have
> implemented our own Pool...
>
> if any one can fix these two bugs (PGConnection from DataSource and
> get/setBytes then we will be able to test it. But at this time we are
> not able to compile new pg.jars)
>
> Dirk
>
>
>>On Mon, 3 Mar 2003, Dirk Bromberg wrote:
>>
>>>Hi,
>>>
>>>i'm using this to get a simple connection sharing:
>>>
>>>Jdbc3PoolingDataSource source = new Jdbc3PoolingDataSource();
>>>source.setDataSourceName("A Data Source");
>>>source.setServerName("localhost");
>>>source.setDatabaseName("test");
>>>source.setUser("testuser");
>>>source.setPassword("testpassword");
>>>source.setMaxConnections(10);
>>>
>>>but how can i get the LargeObjectManager now ??????? i cant cast the
>>>connections to PGConnection!!!
>>>
>>>THX
>>>
>>>Dirk Bromberg
>>>
>>>
>>>---------------------------(end of broadcast)---------------------------
>>>TIP 2: you can get off all lists at once with the unregister command
>>>    (send "unregister YourEmailAddressHere" to majordomo@postgresql.org)
>>>
>>
>>
>>---------------------------(end of broadcast)---------------------------
>>TIP 1: subscribe and unsubscribe commands go to majordomo@postgresql.org
>>
>
>
>
>
> ---------------------------(end of broadcast)---------------------------
> TIP 5: Have you checked our extensive FAQ?
>
> http://www.postgresql.org/docs/faqs/FAQ.html
>




pgsql-jdbc by date:

Previous
From: Barry Lind
Date:
Subject: Re: Postgres PooledConnection...
Next
From: Barry Lind
Date:
Subject: Re: Fw: Can't update rows in tables qualified with schema