The following bug has been logged online: Bug reference: 2882 Logged by: Ravi Email address: [EMAIL PROTECTED] PostgreSQL version: 8.1.4 Operating system: Linux RHEL 3 Description: jdbc driver: date returned from a stored proc is incorrect Details:
This is a PostgreSQL driver issue. The value returned should be Jan 1 1900, instead it returns Jan 2 1900. The failure could be seen only on RHEL3 and not RHEL4. Documented. On Red Hat Enterprise Linux AS release 4 (Nahant Update 3) the milliseconds returned is as follows -2209028400000 = -25567.458333333333333333333333333 = Jan 1 1900 On Red Hat Enterprise Linux AS release 3 (Taroon Update 3) the milliseconds returned is as follows -2208952800000 = -25566.583333333333333333333333333 = Jan 2 1900 Negative indicates before Jan 1 1970. Store Procedure used - create or replace function proc_test_dt1 (a in date) returns date as' begin delete from test_dt; insert into test_dt values(a); return a; end; ' language 'plpgsql' Table was created as follows: create table test_dt(datefld date); The inserted value looks fine. ---------------------------(end of broadcast)--------------------------- TIP 4: Have you searched our list archives? http://archives.postgresql.org