Re: Functional index performance question - Mailing list pgsql-general

From Tom Lane
Subject Re: Functional index performance question
Date
Msg-id 19258.1064932028@sss.pgh.pa.us
Whole thread Raw
In response to Re: Functional index performance question  (Arguile <arguile@lucentstudios.com>)
List pgsql-general
Arguile <arguile@lucentstudios.com> writes:
> On Tue, 2003-09-30 at 07:06, Mike Mascari wrote:
>> SELECT lower(name)
>> FROM employees
>> WHERE lower(name) = 'mike'
>>
>> will PostgreSQL re-evaluate lower(name)? Is it necessary?

> No, it won't re-evaluate.

I think he's asking whether the lower(name) appearing in the output list
will be separately evaluated.  Which it will be.  There's not presently
any code that looks for common subexpressions.

            regards, tom lane

pgsql-general by date:

Previous
From: Robert Creager
Date:
Subject: Re: Divide by zero...
Next
From: Tom Lane
Date:
Subject: Re: [postgis-users] Union as an aggregate