From: | Kevin Grittner <kgrittn(at)ymail(dot)com> |
---|---|
To: | Steve Crawford <scrawford(at)pinpointresearch(dot)com> |
Cc: | Robert Haas <robertmhaas(at)gmail(dot)com>, Vitaly Burovoy <vitaly(dot)burovoy(at)gmail(dot)com>, PostgreSQL Hackers <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: Extracting fields from 'infinity'::TIMESTAMP[TZ] |
Date: | 2015-11-09 16:52:59 |
Message-ID: | 1424580489.860510.1447087979420.JavaMail.yahoo@mail.yahoo.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
> On Mon, Nov 9, 2015 at 8:22 AM, Kevin Grittner <kgrittn(at)ymail(dot)com> wrote:
>> My first choice for other things would be NaN, but throwing an
>> error instead would be OK.
On Monday, November 9, 2015 10:41 AM, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:
> What about returning NULL for the ill-defined cases? That seems
> to comport with SQL's notion of NULL as "unknown/undefined".
On Monday, November 9, 2015 10:44 AM, Steve Crawford <scrawford(at)pinpointresearch(dot)com> wrote:
> Given that null is a "special value that is used to indicate the
> absence of any data value" and that attributes like month or
> day-of-week will have no value for a date of infinity I'd be OK
> with returning null.
NULL seens clearly better than NaN or an error; I wish that had
occurred to me before I posted.
--
Kevin Grittner
EDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company
From | Date | Subject | |
---|---|---|---|
Next Message | Jesper Pedersen | 2015-11-09 16:54:59 | Re: Move PinBuffer and UnpinBuffer to atomics |
Previous Message | Steve Crawford | 2015-11-09 16:44:42 | Re: Extracting fields from 'infinity'::TIMESTAMP[TZ] |