Re: Problem in ResultSet#getTimestamp() of 7.2b4

From: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
To: "Thomas O'Dowd" <tom(at)nooper(dot)com>
Cc: Ryouichi Matsuda <r-matuda(at)sra(dot)co(dot)jp>, barry(at)xythos(dot)com, pgsql-jdbc(at)postgresql(dot)org
Subject: Re: Problem in ResultSet#getTimestamp() of 7.2b4
Date: 2002-02-23 02:09:50
Message-ID: 200202230209.g1N29oW02865@candle.pha.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers pgsql-jdbc


Your patch has been added to the PostgreSQL unapplied patches list at:

http://candle.pha.pa.us/cgi-bin/pgpatches

I will try to apply it within the next 48 hours.

---------------------------------------------------------------------------

Thomas O'Dowd wrote:
> Hi Matsuda-san,
>
> You beat me too it :) The following is a similar patch to the same code.
> I've tested it with your GetTimestampTest.java code and it looks good
> from what I can see. I'm attaching both jdbc1 and jdbc2 patches. This
> patch changes a bit less in the code and basically adds a check to the
> fraction loop for the end of string, as well as a check for a tz before
> adding the GMT bit.
>
> Tom.
>
> On Thu, Jan 17, 2002 at 08:00:01PM +0900, Ryouichi Matsuda wrote:
> > Barry Lind wrote:
> > > Then however I did try your last query:
> > >
> > > select 'now'::timestamp without time zone;
> > >
> > > and this does fail for me with the string index out of bounds exception.
> >
> > An attached patch corrects problem of this bug and fractional second.
> >
> >
> > The handling of time zone was as follows:
> >
> > (a) with time zone
> > using SimpleDateFormat("yyyy-MM-dd HH:mm:ss z")
> > (b) without time zone
> > using SimpleDateFormat("yyyy-MM-dd HH:mm:ss")
> >
> >
> > About problem of fractional second,
> > Fractional second was changed from milli-second to nano-second.
>
> --
> Thomas O'Dowd. - Nooping - http://nooper.com
> tom(at)nooper(dot)com - Testing - http://nooper.co.jp/labs

[ Attachment, skipping... ]

[ Attachment, skipping... ]

>
> ---------------------------(end of broadcast)---------------------------
> TIP 4: Don't 'kill -9' the postmaster

--
Bruce Momjian | http://candle.pha.pa.us
pgman(at)candle(dot)pha(dot)pa(dot)us | (610) 853-3000
+ If your life is a hard drive, | 830 Blythe Avenue
+ Christ can be your backup. | Drexel Hill, Pennsylvania 19026

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Bruce Momjian 2002-02-23 02:12:56 Re: contrib: int_array_aggregator() int_array_enum()
Previous Message Bruce Momjian 2002-02-23 02:06:00 Re: postgresql-7.2b3-betterquote.patch

Browse pgsql-jdbc by date

  From Date Subject
Next Message Bruce Momjian 2002-02-23 02:27:11 Re: [PATCHES] JDBC Connection startup cleaned up
Previous Message Bruce Momjian 2002-02-23 02:07:07 Re: FW: LISTEN/NOTIFY support in JDBC driver?