Re: Default to TIMESTAMP WITH TIME ZONE?

Поиск
Список
Период
Сортировка
От David G. Johnston
Тема Re: Default to TIMESTAMP WITH TIME ZONE?
Дата
Msg-id CAKFQuwbf=TvVOpnqCZOsip6fHpeB-ZhXq61S08-GNfW18O2yDg@mail.gmail.com
обсуждение исходный текст
Ответ на Re: Default to TIMESTAMP WITH TIME ZONE?  (Gavin Flower <GavinFlower@archidevsys.co.nz>)
Ответы Re: Default to TIMESTAMP WITH TIME ZONE?  (Bruce Momjian <bruce@momjian.us>)
Список pgsql-hackers
On Fri, Aug 13, 2021 at 12:33 AM Gavin Flower <GavinFlower@archidevsys.co.nz> wrote:

I always use the tz version, except when I forget.

I find it nearly impossible for me to forget how this works.  But that is probably because I just pretend that the standard, multi-word, data types don't even exist.  It's not that "timestamp" defaults to "WITHOUT TIME ZONE" but rather that there are only two types in existence: timestamp and timestamptz.  It's self-evident which one doesn't handle time zones.


Suspect that it is extremely rare when one would not want to use the TZ
option, which suggests to me that using TZ should be the default.


I would agree, but at this point I'd leave it up to documentation and educational materials to teach/encourage, not runtime behaviors.

David J.

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

Предыдущее
От: Ronan Dunklau
Дата:
Сообщение: Proposal: More structured logging
Следующее
От: Alexander Kukushkin
Дата:
Сообщение: Re: pg_settings.pending_restart not set when line removed