Re: timestamp with/without time zone - Mailing list pgsql-hackers

From Tom Lane
Subject Re: timestamp with/without time zone
Date
Msg-id 4132.993223762@sss.pgh.pa.us
Whole thread Raw
In response to Re: timestamp with/without time zone  (Bruce Momjian <pgman@candle.pha.pa.us>)
List pgsql-hackers
Thomas Lockhart <lockhart@fourpalms.org> writes:
> The description in pg_dump was chosen to assist with a transition in the
> next version of PostgreSQL to having available a true "no time zone"
> timestamp, leaving the current implementation as the "time zone aware"
> type. I'm concerned about changing the current choice in the absence of
> thought about this issue.

I already commented what I thought about this: the current type is not
either of the SQL-compatible timestamp types, and if we want to support
the SQL-compatible semantics then we need three types, not two.

> On a related note, I've been thinking about removing the following
> features from our current "timestamp":

> o timestamp 'invalid' - an interesting concept which might actually be
> useful for the original abstime type since it has such a limited range,
> but not generally useful for timestamp. I'd suggesting leaving it in for
> abstime, at least for now.

> o timestamp 'current' - another interesting concept not likely used by
> anyone, and causing conniptions for our optimizer (one cannot cache
> results for datasets containing this value).

I believe everyone already agreed that 'current' should be removed.
'invalid' seems somewhat redundant with NULL, so I wouldn't object to
taking it out; on the other hand, is it hurting anything?  Also, it
seems a bad idea to remove it from timestamp if we leave it in abstime;
you shouldn't have to worry that casting abstime up to timestamp might
fail.
        regards, tom lane


pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: 7.2 release and index_formtuple
Next
From: Thomas Lockhart
Date:
Subject: Re: timestamp with/without time zone