launchpad-dev team mailing list archive
-
launchpad-dev team
-
Mailing list archive
-
Message #04732
Re: Performance question
Hi
>> Few people use prepared statements with PostgreSQL as they are rarely
>> a win. With a prepared statement, a query plan must be chosen without
>> paying attention to the arguments and this will often perform much
>> worse than a query plan that is chosen when the arguments are known -
>
> Exactly: prepared statements are a way to win a few milliseconds, but
> also a way to lose seconds or even minutes.
>
Ah, ok. Things are somewhat different with Oracle :-) I'll have to do
some more reading on Postgres.
>
> Even when it's not, we'd probably ask "why are we executing this query
> so often?" before we'd ask "can we shave some planning time off this
> query?"
>
+100. We've already been having such discussions within my team. But
no-one seemed to be able to shed any light on the prepared statement
question, hence a post to the list :-)
Thanks again for the collective wisdom.
References