On Fri, Feb 26, 2010 at 09:50, Robert Haas <robertmhaas@gmail.com> wrote:
> On Fri, Feb 26, 2010 at 1:29 AM, Alex Hunsaker <badalex@gmail.com> wrote:
>> Prepared plans + exec plan (new guc/ protocol thing):
>> Use: not quite sure
>> Problems: slow because it would replan every time
>> Solutions: use a prepared plan with the appropriate things not
>> parametrized...?
>>
>> [ aka we already have this, its called dont use a prepared statement ]
>
> The point is sometimes you'd like to replan every time, but not
> reparse every time. There's no way to do that ATM.
So what you save on parse time? Maybe that's worth it. I've never
run the numbers nor have I seen them in this thread. I probably
missed em... My _hunch_ is planning will on average take
significantly longer than parse time (read in the noise of plan time).But that's unfounded :) I can certainly imagine
caseswhere you have
HUGE queries where the parse time too slow-- wont the plan most of the
time be an order of magnitude slower? Anyway Ill stop until I get a
chance to do _some_ kind of benchmarking, I'm really quite clueless
here.