Re: funkiness with '1999-12-31 19:00:00-05'::timestamp with time zone - Mailing list pgsql-general

From Tom Lane
Subject Re: funkiness with '1999-12-31 19:00:00-05'::timestamp with time zone
Date
Msg-id 28273.1283542603@sss.pgh.pa.us
Whole thread Raw
In response to Re: funkiness with '1999-12-31 19:00:00-05'::timestamp with time zone  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-general
[ trivia warning ]

I wrote:
> We don't make any great effort to expose that though.  It looks like
> the closest value that timestamptzin makes different from zero is

> regression=# select extract(epoch from '1999-12-31 19:00:00.00000000001-05' - '1999-12-31 19:00:00-05'::timestamptz)
;
>       date_part
> ----------------------
>  1.45519152283669e-11
> (1 row)

Actually, it looks like the precision is being limited by the rotation
from EST zone.  In GMT zone I can do this:

regression=# select extract(epoch from '2000-01-01
00:00:00.0000000000000000000000000000000000000000000000000000000000000000001'::timestamptz- '2000-01-01 00:00:00'); 
 date_part
-----------
     1e-67
(1 row)

and it could go a lot smaller except there's an arbitrary limit on
the length of input string that timestamptzin will take.

If float timestamps weren't deprecated it might be worth trying to make
this behave less surprisingly.

            regards, tom lane

pgsql-general by date:

Previous
From: Josh Kupershmidt
Date:
Subject: Re: funkiness with '1999-12-31 19:00:00-05'::timestamp with time zone
Next
From: Tom Lane
Date:
Subject: Re: funkiness with '1999-12-31 19:00:00-05'::timestamp with time zone