Search Postgresql Archives

Re: Interval "1 month" is equals to interval "30 days" - WHY?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Craig Ringer wrote:
>> Of course this is not always correct.
>> But what should the result of
>>    INTERVAL '1 month' = INTERVAL '30 days'
>> be?  FALSE would be just as wrong.

> NULL? In all honesty, it's a reasonable fit for NULL in its
> "uncertain/unknowable" personality,  because two intervals that don't
> use the same time scales aren't truly comparable for equality.

Hmmm.  How would you define an ordering in that case?
And without an ordering, you couldn't use "btree" indexes
on interval columns, right?

Yours,
Laurenz Albe

-- 
Sent via pgsql-general mailing list (pgsql-general@xxxxxxxxxxxxxx)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general



[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux