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

Re: JDBC Driver Modifies Calendar passed into setTimestamp()

From: Dave Cramer <pg(at)fastcrypt(dot)com>
To: Michael Youngstrom <youngm(at)gmail(dot)com>
Cc: pgsql-jdbc(at)postgresql(dot)org
Subject: Re: JDBC Driver Modifies Calendar passed into setTimestamp()
Date: 2005-04-26 17:08:22
Message-ID: 426E7586.4050707@fastcrypt.com (view raw or flat)
Thread:
Lists: pgsql-jdbc
I'd suggest that we shouldn't be modifying the calendar object either.

Without looking at the bug, I'd probably agree with him.

dave

Michael Youngstrom wrote:

>There appears to be a possible problem with PreparedStatement's
>
>setTimestamp(int parameterIndex, Timestamp x, Calendar cal)
>
>The Calendar object passed into this method is modified by
>PostgreSQL's JDBC driver.  This causes problems with Hibernate.  I
>offered a solution for hibernate to clone the calendar before calling
>the method but Gavin King of Hibernate believes it's the JDBC driver's
>problem.  Here is the link to the hibernate bug discussed.
>
>http://opensource.atlassian.com/projects/hibernate/browse/HHH-405
>
>Mike
>
>---------------------------(end of broadcast)---------------------------
>TIP 5: Have you checked our extensive FAQ?
>
>               http://www.postgresql.org/docs/faq
>
>
>  
>

-- 
Dave Cramer
http://www.postgresintl.com
519 939 0336
ICQ#14675561


In response to

Responses

pgsql-jdbc by date

Next:From: Oliver JowettDate: 2005-04-26 21:23:24
Subject: Re: JDBC Driver Modifies Calendar passed into setTimestamp()
Previous:From: Michael YoungstromDate: 2005-04-26 16:58:33
Subject: JDBC Driver Modifies Calendar passed into setTimestamp() creates problem with Hibernate

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