Markus Schaber wrote:
> Hi, Oliver,
> Oliver Jowett wrote:
>>Isn't this just a very roundabout way of overriding the planner? i.e.
>>what you are really doing is saying "ignore your statistics, I know more
>>about the parameter values I'm going to give you than I'm actually
> No, it's telling the planner "You can assume that all those queries for
> my statement are similar enough that the same query plan will fit them,
> so you can safe the overhead of both parsing and planning".
What I mean is, if you are prepared to say that, what you are really
wanting is to second-guess the planner and tell the server "use *THIS*
plan" explicitly .. In both approaches, you (the app developer) need
detailed knowledge about what sort of plans work for the parameters &
query you are using (for your particular server version and dataset etc).
Doing that at the Parse/Bind level doesn't seem right and in fact seems
even more errorprone than explicitly specifying a plan, since you are
relying on the planner picking a particular plan for a particular set of
parameter values that you happened to use first which may or may not
always be true depending on things like the current state of DB statistics..
In response to
pgsql-jdbc by date
|Next:||From: till toenges||Date: 2006-09-26 13:07:12|
|Subject: Re: bytea memory improvement|
|Previous:||From: Markus Schaber||Date: 2006-09-26 12:00:45|
|Subject: Re: Bind message|