From: | Kris Jurka <books(at)ejurka(dot)com> |
---|---|
To: | Achilleas Mantzios <achill(at)matrix(dot)gatewaynet(dot)com> |
Cc: | pgsql-jdbc(at)postgresql(dot)org, Oliver Jowett <oliver(at)opencloud(dot)com> |
Subject: | Re: Timestamps without time zone |
Date: | 2008-01-11 05:12:24 |
Message-ID: | Pine.BSO.4.64.0801110007010.3943@leary.csoft.net |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-jdbc |
On Thu, 10 Jan 2008, Achilleas Mantzios wrote:
> I tried other apps with the new postgresql-8.2-507.jdbc3.jar and some of
> them break. So i will need to live with the 7.4.19 driver for a while.
Without an actual failure it's tough to advise you here. You might try
the URL option protocolVersion=2 or stringtype=unspecified to solve some
of the more common problems people have come across with the upgrade as a
workaround.
> One question, is there a way to get a hold of the Default TimeZone
> instance of the JVM (lets call it default_TZ) and put all code that
> alter it in some sort of
> synchronized (default_TZ) {
> TimeZone.setDefault(TimeZone.getTimeZone("UTC"));
> // jdbc calls here that deal with timestamps without time zone
> java.util.TimeZone.setDefault(null);
> }
> block?
This seems unlikely to work. Everyone would have to get the default_TZ
object before doing any TZ manipulation so they'd synchronzie on the same
object. And there's no way you can control other code that just wants
to print out a date. It's not going to synchronize itself on anything.
Kris Jurka
From | Date | Subject | |
---|---|---|---|
Next Message | Kris Jurka | 2008-01-11 05:22:09 | Re: Patch for Statement.getGeneratedKeys() |
Previous Message | mp.rajkhowa | 2008-01-11 04:51:36 | Autocommit Problem |