CREATE FUNCTION distributors_id_max() RETURNS INT4 AS Bad Timestamp Format thrown by jdbc7.0-1.2.jar - Mailing list pgsql-bugs

From Kevin Gilpin
Subject CREATE FUNCTION distributors_id_max() RETURNS INT4 AS Bad Timestamp Format thrown by jdbc7.0-1.2.jar
Date
Msg-id 3A34E9F7.206D4FCB@alum.mit.edu
Whole thread Raw
List pgsql-bugs
I have created a table with a DATETIME column:

create table registereduser
(
    ...

    registeredDate DATETIME NOT NULL
)

I inserted a new record into this table, with the registeredDate = new
Timestamp(new Date().getTime()))

On retrieving this record, the following stack trace ensued:

Exception in thread "main" Bad Timestamp Format at 19 in 2000-12-11
09:43:50.20-05
        at
org.postgresql.jdbc2.ResultSet.getTimestamp(ResultSet.java:447)
        at weblogic.db.jdbc.Value.<init>(Value.java:129)
        at weblogic.db.jdbc.Record.internal_fetch(Record.java:1376)
        at weblogic.db.jdbc.DataSet.fetchRecords(DataSet.java:284)
        at
weblogic.db.jdbc.TableDataSet.fetchRecords(TableDataSet.java:173)
        at weblogic.db.jdbc.DataSet.fetchRecords(DataSet.java:234)
        at test.database.TInsert_1.run(TInsert_1.java:138)
        at test.database.TInsert_1.main(TInsert_1.java:26)

The weblogic classes are dbKona.

I expect that for some reason the JDBC driver is not dealing with the
'-5' time zone data (I am in US Central Time).

- kevin

pgsql-bugs by date:

Previous
From: Stu Coates
Date:
Subject: 7.1beta1 JDBC bug?
Next
From: Vasko Miroslav
Date:
Subject: obsolete version of python bindings