BUG #14944: Error for 6 digit year in date comparision - Mailing list pgsql-bugs

From abedi0501@gmail.com
Subject BUG #14944: Error for 6 digit year in date comparision
Date
Msg-id 20171204091833.27106.81427@wrigleys.postgresql.org
Whole thread Raw
Responses Re: BUG #14944: Error for 6 digit year in date comparision  (Francisco Olarte <folarte@peoplecall.com>)
List pgsql-bugs
The following bug has been logged on the website:

Bug reference:      14944
Logged by:          Akash Bedi
Email address:      abedi0501@gmail.com
PostgreSQL version: 9.5.4
Operating system:   Ubuntu 16/Windows 10
Description:

I'm noticing errors during date comparison, 

--Below works fine
select '99999-01-01'::date > now();
?column?
----------
 t
(1 row)

--Gives error
select '999999-01-01'::date > now();
ERROR:  date out of range for timestamp

Database allows to store date ranges until 5874897 AD '5874897-01-01'::date
but date comparison fails.



pgsql-bugs by date:

Previous
From: Сергей А. Фролов
Date:
Subject: Re: BUG #14940: Duplicated records inspite of primary key and uniqueconstraint
Next
From: Francisco Olarte
Date:
Subject: Re: BUG #14944: Error for 6 digit year in date comparision