Re: "iscachable" functions

From: Jeff Eckermann <jeff_eckermann(at)yahoo(dot)com>
To: "Eric B(dot)Ridge" <ebr(at)tcdi(dot)com>, pgsql-general(at)postgresql(dot)org
Subject: Re: "iscachable" functions
Date: 2003-02-14 21:38:27
Message-ID: 20030214213827.17386.qmail@web20809.mail.yahoo.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

--- "Eric B.Ridge" <ebr(at)tcdi(dot)com> wrote:
> For the "iscachable" parameter of CREATE FUNCTION,
> the 7.2.x
> documentation states:
> "Iscachable indicates that the function always
> returns the same result
> when given the same argument values (i.e., it does
> not do database
> lookups or otherwise use information not directly
> present in its
> parameter list). The optimizer uses iscachable to
> know whether it is
> safe to pre-evaluate a call of the function."
>
> But where is this cache? Is it per backend
> connection, or is it shared
> among all backends? Also, is there a way to
> invalidate this cache or
> otherwise expire the values?
>
There isn't any cache: the choice of name is
misleading. "iscachable" means nothing more than the
docs quote says. The usefulness of it lies in being
able to index the return value of the function.

__________________________________________________
Do you Yahoo!?
Yahoo! Shopping - Send Flowers for Valentine's Day
http://shopping.yahoo.com

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Tom Lane 2003-02-14 21:42:37 Re: Maximum size of the primary key
Previous Message Bruno Wolff III 2003-02-14 21:37:03 Re: operators and bit field