I'm forwarding part of the response to a query for information I'd sent related to this. The interesting thing here I think is the to_timestamp returns for 1901/12/13 and 1901/12/14.
------ db1=> select cast(timestamptz '1901/12/13' as date); date ------------ 1901-12-13 (1 row) db1=> select cast(timestamptz '1901/12/14' as date); date ------------ 1901-12-13 (1 row) db1=> select to_timestamp('1901/12/13', 'YYYY/MM/DD'); to_timestamp --------------------- 1901-12-13 00:00:00 (1 row) db1=> select to_timestamp('1901/12/14', 'YYYY/MM/DD'); to_timestamp --------------------- 1901-12-13 13:00:00 (1 row) db1=> select to_date('1901/12/13', 'YYYY/MM/DD'); to_date ------------ 1901-12-13 (1 row) db1=> select to_date('1901/12/14', 'YYYY/MM/DD'); to_date ------------ 1901-12-13 (1 row) db1=> db1=> select timestamptz '1901/12/14'; timestamptz --------------------- 1901-12-13 13:00:00 (1 row) db1=> select timestamptz '1901/12/13'; timestamptz --------------------- 1901-12-13 00:00:00 (1 row) ================================================================ -----Original Message----- From: Stephan Szabo [mailto:[EMAIL PROTECTED] Sent: Thursday, 21 August 2003 3:53 AM To: Arnold Mavromatis Cc: Lan Tran; '[EMAIL PROTECTED]'; '[EMAIL PROTECTED]' Subject: Re: FW: FW: [BUGS] postgresql 7.3.2 bug on date '1901-12-13' and '190 1-12 Noone seems to have jumped on this yet, so I figured I'd do a little more looking. Unfortunately in the end, you may need to do some grotting around with a debugger. :( What do select timestamptz '1901/12/13'; select timestamptz '1901/12/14'; select cast(timestamptz '1901/12/13' as date); select cast(timestamptz '1901/12/14' as date); select to_timestamp('1901/12/13', 'YYYY/MM/DD'); select to_timestamp('1901/12/14', 'YYYY/MM/DD'); select to_date('1901/12/13', 'YYYY/MM/DD'); select to_date('1901/12/14', 'YYYY/MM/DD'); give you? I'd also suggest considering building a 7.3.4 system and seeing if you get the same odd results from there. ---------------------------(end of broadcast)--------------------------- TIP 5: Have you checked our extensive FAQ? http://www.postgresql.org/docs/faqs/FAQ.html