Martijn van Oosterhout wrote:
On Sat, Oct 04, 2008 at 08:30:32PM -0400, Joseph S wrote:
In this case, with the function being called over and over again inside
a nested loop, it would be worth the effort. I'm not even talking about
caching the result for the whole transaction block, just repla
On Sat, Oct 04, 2008 at 08:30:32PM -0400, Joseph S wrote:
> In this case, with the function being called over and over again inside
> a nested loop, it would be worth the effort. I'm not even talking about
> caching the result for the whole transaction block, just replacing the
> function call
Tom Lane wrote:
"Gurjeet Singh" <[EMAIL PROTECTED]> writes:
Shouldn't PG make all efforts to not execute something when the result is
already known?
Not if said effort would cost more than is saved, which would be by far
the most likely result if we tried to cache all function results.
On Sat, Oct 4, 2008 at 6:06 PM, Gregory Stark <[EMAIL PROTECTED]>wrote:
> "Gurjeet Singh" <[EMAIL PROTECTED]> writes:
>
> > On Sat, Oct 4, 2008 at 8:49 AM, Tom Lane <[EMAIL PROTECTED]> wrote:
> >
> >> "Gurjeet Singh" <[EMAIL PROTECTED]> writes:
> >> > Shouldn't PG make all efforts to not execute s
"Gurjeet Singh" <[EMAIL PROTECTED]> writes:
> On Sat, Oct 4, 2008 at 8:49 AM, Tom Lane <[EMAIL PROTECTED]> wrote:
>
>> "Gurjeet Singh" <[EMAIL PROTECTED]> writes:
>> > Shouldn't PG make all efforts to not execute something when the result is
>> > already known?
>>
>> Not if said effort would cost
On Sat, Oct 4, 2008 at 8:49 AM, Tom Lane <[EMAIL PROTECTED]> wrote:
> "Gurjeet Singh" <[EMAIL PROTECTED]> writes:
> > Shouldn't PG make all efforts to not execute something when the result is
> > already known?
>
> Not if said effort would cost more than is saved, which would be by far
> the most
"Gurjeet Singh" <[EMAIL PROTECTED]> writes:
> Shouldn't PG make all efforts to not execute something when the result is
> already known?
Not if said effort would cost more than is saved, which would be by far
the most likely result if we tried to cache all function results.
On Sat, Oct 4, 2008 at 1:36 AM, Tom Lane <[EMAIL PROTECTED]> wrote:
> Joseph S <[EMAIL PROTECTED]> writes:
> > Aren't static functions supposed to executed only once per transaction?
>
> There's no promise of that.
>
Can this be changed? Or does it work only in simpler queries, based on some
resu
On Fri, 03 Oct 2008, Joseph S <[EMAIL PROTECTED]> writes:
> Aren't static functions supposed to executed only once per transaction?
There is no such promise, that depends on the PL you prefer. For
instance, in PL/scheme[1] non-volatile (immutable) and non-SRF functions
are cached per (top) transac
Joseph S <[EMAIL PROTECTED]> writes:
> Aren't static functions supposed to executed only once per transaction?
There's no promise of that.
regards, tom lane
--
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
http:/
Umm r/static/stable
--
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general
Aren't static functions supposed to executed only once per transaction?
I have a query plan that looks like this:
Unique (cost=441872.58..441875.39 rows=562 width=4)
-> Sort (cost=441872.58..441873.98 rows=562 width=4)
Sort Key: elog.uid
-> Nested Loop (cost=89.52..441
12 matches
Mail list logo