Re: timestamp resolution? - Mailing list pgsql-hackers

From Thomas Lockhart
Subject Re: timestamp resolution?
Date
Msg-id 3BBCC3CE.5C72EA31@fourpalms.org
Whole thread Raw
In response to timestamp resolution?  (Tatsuo Ishii <t-ishii@sra.co.jp>)
List pgsql-hackers
> No, it's just that CURRENT_TIMESTAMP doesn't presently reduce its
> precision, as you assert it should do.  However, I see nothing in SQL99
> 6.19 that asserts anything about the precision of CURRENT_TIMESTAMP
> without a precision indicator.  It just says
>          2) If specified, <time precision> and <timestamp precision>
>             respectively determine the precision of the time or timestamp
>             value returned.
> which seems to leave it up to us to choose the behavior when no
> precision is specified.  I'd prefer to see CURRENT_TIMESTAMP return as
> much precision as possible (see also previous message).

Hmm. Somewhere else it *does* specify a precision of zero for TIME and
TIMESTAMP; wonder why that rule wouldn't apply to CURRENT_TIME etc too?
Not that lots of precision isn't good, but I'd like to be consistant.

> BTW, CURRENT_TIME and CURRENT_TIMESTAMP should return TIMETZ and
> TIMESTAMPTZ respectively, but currently do not --- are you fixing that?

Yup. Though I'm not certain that it would effectively be any different.
                     - Thomas


pgsql-hackers by date:

Previous
From: Thomas Lockhart
Date:
Subject: Re: Timestamp, fractional seconds problem
Next
From: Thomas Lockhart
Date:
Subject: Re: Beta time