Re: SQL code runs slower as a stored function - Mailing list pgsql-general

From Tom Lane
Subject Re: SQL code runs slower as a stored function
Date
Msg-id 18588.1273778371@sss.pgh.pa.us
Whole thread Raw
In response to Re: SQL code runs slower as a stored function  (Stephen Frost <sfrost@snowman.net>)
List pgsql-general
Stephen Frost <sfrost@snowman.net> writes:
> * S G (sgennaria2@gmail.com) wrote:
>> I guess to really get down to the issue, I'm curious if what I'm doing is
>> considered 'standard procedure' to others-- i.e. using funny workarounds
>> like building the query in a text var and executing it with plpgsql's RETURN
>> QUERY EXECUTE command.

> It's certainly not unusual when it's necessary.  We do try to minimize
> the times it's necessary by making the planner as smart as possible.

Yeah.  This is a known sore spot that I hope to do something about in
the 9.1 development cycle.

            regards, tom lane

pgsql-general by date:

Previous
From: Tom Lane
Date:
Subject: Re: Persistence problem
Next
From: Vick Khera
Date:
Subject: Re: pg_dumpall for Postgres Database Daily Backup