Re: Prepared statements considered harmful - Mailing list pgsql-hackers

From Merlin Moncure
Subject Re: Prepared statements considered harmful
Date
Msg-id b42b73150608311026m4c37202dtc6ba3288dca14f12@mail.gmail.com
Whole thread Raw
In response to Re: Prepared statements considered harmful  (Peter Eisentraut <peter_e@gmx.net>)
List pgsql-hackers
On 8/31/06, Peter Eisentraut <peter_e@gmx.net> wrote:
> Am Donnerstag, 31. August 2006 15:05 schrieb Merlin Moncure:
> > The proposal to supply hints to statements and functions has been
> > voted down several times due to the argument that it is better to fix
> > the planner.  I think supplying hints does fix the planner, and is a
> > balanced solution.
>
> Planner hints are a way to address a deficient planner.  But neither a
> manually hinted planner nor a perfectly good planner will help if the
> planning decisions are based on outdated information.

right, anyways it's clearer now what you are suggesting and I think
your idea regarding impicitly generated plans has some merit.  the
major annoyance for me is I have to force disconnect anytime there is
a schema search_path change.

query hints, which I still think would make my life much easier, do
not have much to do with the thrust of your argument.

I think, maybe to add some intelligence to implicit plan generation
parhaps guarded by GUC:
implicit_plan_generation=[none, smart, all]
with smart meaning some defined events including perhaps:
* creation or deletion of temp table
* duration of time
* user invocation
* manipulation of search_path

just thinking out loud here,
merlin


pgsql-hackers by date:

Previous
From: Martijn van Oosterhout
Date:
Subject: Re: Prepared statements considered harmful
Next
From: Gregory Stark
Date:
Subject: Re: Prepared statements considered harmful