Re: Re: Proposed changing the definition of decade for date_trunc and extract

Поиск
Список
Период
Сортировка
От David Johnston
Тема Re: Re: Proposed changing the definition of decade for date_trunc and extract
Дата
Msg-id CAKFQuwb+=N1BUJ-6fie0quXqcmWNNwHva709ehkd+zCUgb=Quw@mail.gmail.com
обсуждение исходный текст
Ответ на Re: Re: Proposed changing the definition of decade for date_trunc and extract  (Gavin Flower <GavinFlower@archidevsys.co.nz>)
Список pgsql-hackers

On Fri, Aug 1, 2014 at 8:15 PM, Gavin Flower <GavinFlower@archidevsys.co.nz> wrote:
On 02/08/14 12:32, David G Johnston wrote:

Any supporting arguments for 1-10 = 1st decade other than technical
perfection?  I guess if you use data around and before 1AD you care about
this more, and rightly so, but given sound arguments for both methods the
one more useful to more users who I suspect dominantly care about years >
1900.

So -1 to change for breaking backward compatibility and -1 because the
current behavior seems to be more useful in everyday usage.

Since there was no year zero: then it follows that the first decade comprises years 1 to 10, and the current Millennium started in 2001 - or am I being too logical???   :-)


​This is SQL, only relational logic matters.  All other logic can be superseded by committee consensus.

IOW - and while I have no way of checking - this seems like something that may be governed by the SQL standard...in which case adherence to that would trump mathematical logic.

David J.


В списке pgsql-hackers по дате отправления:

Предыдущее
От: Gavin Flower
Дата:
Сообщение: Re: Re: Proposed changing the definition of decade for date_trunc and extract
Следующее
От: Noah Misch
Дата:
Сообщение: Re: B-Tree support function number 3 (strxfrm() optimization)