From: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
---|---|
To: | Michael Glaesemann <grzm(at)myrealbox(dot)com> |
Cc: | Josh Berkus <josh(at)agliodbs(dot)com>, pgsql-hackers(at)postgresql(dot)org |
Subject: | Re: Interval->day proposal |
Date: | 2005-06-01 14:27:56 |
Message-ID: | 13746.1117636076@sss.pgh.pa.us |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Michael Glaesemann <grzm(at)myrealbox(dot)com> writes:
> On Jun 1, 2005, at 1:42 PM, Michael Glaesemann wrote:
>> -- v8.0.3
>> test=# select '25 hours'::interval;
>> interval
>> ----------------
>> 1 day 01:00:00
>> (1 row)
>>
>> -- new interval code
>> test=# select '25 hours'::interval;
>> interval
>> ----------
>> 25:00:00
>> (1 row)
>>
>> I'll be digging into the spec later and post what I find. Thoughts?
> I've dug a bit, and this is definitely not spec compliant, as
> interval hours must be in the range 0-23.
Doesn't bother me. The spec says what results you must get from
spec-compliant input; I don't think it says we may take only
spec-compliant input. (If we were to read it that way, we'd have
to rip out every PG extension, not only the interval-related ones.)
The entire *point* of this change is to be able to distinguish
"25 hours" from "1 day 1 hour", so you can hardly argue that being
able to do that is not what we want it to do...
regards, tom lane
From | Date | Subject | |
---|---|---|---|
Next Message | Tom Lane | 2005-06-01 14:31:07 | Re: Interval->day proposal |
Previous Message | Brusser, Michael | 2005-06-01 14:27:04 | fdatasync failed, I/O error |