Re: Why *exactly* is date_trunc() not immutable ?

Поиск
Список
Период
Сортировка
От Alban Hertroys
Тема Re: Why *exactly* is date_trunc() not immutable ?
Дата
Msg-id 45D96814.2070702@magproductions.nl
обсуждение исходный текст
Ответ на Re: Why *exactly* is date_trunc() not immutable ?  (Michael Glaesemann <grzm@seespotcode.net>)
Ответы Re: Why *exactly* is date_trunc() not immutable ?  (Michael Glaesemann <grzm@seespotcode.net>)
Список pgsql-general
Michael Glaesemann wrote:
>
> On Feb 18, 2007, at 20:29 , Karsten Hilbert wrote:
>
>> What I don't understand, however, is exactly *why* date_trunc is not
>> immutable ?
>
> I believe it's because the result of date_trunc depends on the time zone
> setting for the session.

I understand the reasoning, but _under the conditions_ it is being used
by the OP it could have been immutable, right?

The index values will still match up with the queried values if they are
in the same time zone.

I'm not asking to change it back to immutable (it isn't), I just
realized that the stability of functions may actually be conditional.

--
Alban Hertroys
alban@magproductions.nl

magproductions b.v.

T: ++31(0)534346874
F: ++31(0)534346876
M:
I: www.magproductions.nl
A: Postbus 416
   7500 AK Enschede

// Integrate Your World //

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

Предыдущее
От: "Albe Laurenz"
Дата:
Сообщение: Re: WARNING: some databases have not been vacuumed in 1953945422 transactions
Следующее
От: Michael Glaesemann
Дата:
Сообщение: Re: Why *exactly* is date_trunc() not immutable ?