Re: Bug in TimestampUtils.java?

From: Richard Cook <awhig(at)yahoo(dot)com>
To: Oliver Jowett <oliver(at)opencloud(dot)com>
Cc: imad <immaad(at)gmail(dot)com>, pgsql-jdbc(at)postgresql(dot)org
Subject: Re: Bug in TimestampUtils.java?
Date: 2006-11-10 16:19:40
Message-ID: 20061110161940.19582.qmail@web60222.mail.yahoo.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-jdbc

Oliver,

Below is the debug output from TimestampUtils.java

It parses the date string that says -05 into an -0400 Date object.

Rich

Date String: 2006-10-29 23:00:00-05

debug output ---> Parsed date '2006-10-29 23:00:00-05' in zone America/New_York as 2006-10-29 AD 00:00:00 -0400 (millis=1162094400000)

----- Original Message ----
From: Oliver Jowett <oliver(at)opencloud(dot)com>
To: Richard Cook <awhig(at)yahoo(dot)com>
Cc: imad <immaad(at)gmail(dot)com>; pgsql-jdbc(at)postgresql(dot)org
Sent: Friday, November 10, 2006 1:20:05 AM
Subject: Re: [JDBC] Bug in TimestampUtils.java?

Richard Cook wrote:

> If you look at the source code for the postgres jdbc driver, it
> retrieves the column as a string, then uses the TimeStampUtils class to
> create a date or timestamp out of it. I think the driver is incorrectly
> setting the timezone when it creates the Date object.

I missed the original post here, but if you retrieve the result as a
String what do you get? (the exact value please) .. and how does that
compare to the Date you get?

-O

Responses

Browse pgsql-jdbc by date

  From Date Subject
Next Message Heikki Linnakangas 2006-11-10 16:25:19 Re: [Fwd: FAQ update about transaction interleaving]
Previous Message Heikki Linnakangas 2006-11-10 16:07:52 Re: XA end then join fix for WebLogic