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

From: Michael Glaesemann <grzm(at)seespotcode(dot)net>
To: Alban Hertroys <alban(at)magproductions(dot)nl>
Cc: Karsten Hilbert <Karsten(dot)Hilbert(at)gmx(dot)net>, pgsql-general <pgsql-general(at)postgresql(dot)org>
Subject: Re: Why *exactly* is date_trunc() not immutable ?
Date: 2007-02-19 09:10:56
Message-ID: 78C0B131-604A-40AD-8C09-B59CF407E7D1@seespotcode.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general


On Feb 19, 2007, at 18:04 , Alban Hertroys wrote:

> 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?

*Under the conditions* doesn't really make sense wrt immutable
functions. Immutable means is immutable under all conditions.

Michael Glaesemann
grzm seespotcode net

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Michael Glaesemann 2007-02-19 09:11:54 Re: Why *exactly* is date_trunc() not immutable ?
Previous Message Alban Hertroys 2007-02-19 09:04:20 Re: Why *exactly* is date_trunc() not immutable ?