Re: Constraint exclusion can't process simple constant expressions?

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Josh Berkus <josh(at)agliodbs(dot)com>
Cc: pgsql-performance(at)postgresql(dot)org
Subject: Re: Constraint exclusion can't process simple constant expressions?
Date: 2011-04-21 02:44:50
Message-ID: 27886.1303353890@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-performance

Josh Berkus <josh(at)agliodbs(dot)com> writes:
>> timestamptz + interval is not immutable --- in fact, the particular
>> example you give (ts + '1 day') is certainly dependent on timezone
>> setting.

> Why not? Given that the time zone will be the same for both the
> timestamptz and the interval, how would the result not be immutable?

The reason it depends on the timezone is that the result varies if
"plus one day" means crossing a DST boundary.

regards, tom lane

In response to

Browse pgsql-performance by date

  From Date Subject
Next Message Pavel Stehule 2011-04-21 06:01:54 Re: %100 CPU on Windows Server 2003
Previous Message Josh Berkus 2011-04-21 02:18:23 Re: Constraint exclusion can't process simple constant expressions?