X-Original-To: pgsql-jdbc-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [64.117.225.181]) by svr1.postgresql.org (Postfix) with ESMTP id 54E7CD1C4C9 for ; Mon, 21 Jul 2003 18:56:10 +0000 (GMT) Received: from svr1.postgresql.org ([64.117.224.193]) by localhost (svr5.postgresql.org [64.117.225.181]) (amavisd-new, port 10024) with ESMTP id 02925-06 for ; Mon, 21 Jul 2003 18:55:59 +0000 (GMT) Received: from mail.xythos.com (unknown [206.14.210.116]) by svr1.postgresql.org (Postfix) with ESMTP id 3B538D1C4CA for ; Mon, 21 Jul 2003 15:55:59 -0300 (ADT) Received: from ravms by mail.xythos.com with mail-ok (Exim 3.36 #3) id 19efpI-00065g-00; Mon, 21 Jul 2003 18:56:00 +0000 Received: from ip-216-36-77-241.dsl.sjc.megapath.net ([216.36.77.241] helo=xythos.com) by mail.xythos.com with asmtp (Exim 3.36 #3) id 19efpH-00065V-00; Mon, 21 Jul 2003 18:55:59 +0000 Message-ID: <3F1C373F.7070409@xythos.com> Date: Mon, 21 Jul 2003 11:55:59 -0700 From: Barry Lind User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.2.1) Gecko/20030225 X-Accept-Language: en-us, en MIME-Version: 1.0 To: Raymond Chui Cc: pgsql-jdbc@postgresql.org Subject: Re: Timestamp problem References: <3F1452EE.7000509@noaa.gov> In-Reply-To: <3F1452EE.7000509@noaa.gov> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-Envelope-To: raymond.chui@noaa.gov, pgsql-jdbc@postgresql.org X-Virus-Scanned: by amavisd-new at postgresql.org X-Archive-Number: 200307/241 X-Sequence-Number: 7625 Raymond, Upgrade to the latest stable driver. You can download it from jdbc.postgresql.org. --Barry Raymond Chui wrote: > I am use PostgreSQL 7.2.1 in Redhat Linux 7.2 > Java 1.4.x > > When I do JDBC > > String sql = "SELECT datetime_column FROM mytable"; > .... > > Timestamp ts = resultSet.getTimestamp(2); > > If the timestamp return format like > > 2003-07-15 13:20:00.20+00 > > then is OK. But if timestamp return like > > 2003-07-15 13:20:00.421+00 > > Then I got SQLException > > Bad Timestamp Format at 23 in 2003-07-14 14:45:00.421+00 > > What is 23? > How do I resolve this problem? > > Thank Q! >