Re: Delaying the planning of unnamed statements until Bind

From: Oliver Jowett <oliver(at)opencloud(dot)com>
To: Heikki Linnakangas <hlinnaka(at)iki(dot)fi>
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: Delaying the planning of unnamed statements until Bind
Date: 2004-05-30 22:45:11
Message-ID: 40BA63F7.80001@opencloud.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Heikki Linnakangas wrote:

> I'm worried about plan stability if we enable it by default. It could
> lead to nasty, hard to reproduce performance problems. Think about this
> scenario:

This is my main concern with the approach Tom suggested.

> Also keep in mind that at least some application servers have a
> client-side prepared statement cache, so that even if the application
> used a non-prepared statement for the reports, the middleware prepares it
> anyway.

It's less of an issue if we only use this behaviour when binding the
unnamed statement. The unnamed statement is quite "special" and is
unlikely to be reused accidentally (for one thing, you can only have one
unnamed statement..)

The patch I posted to -patches earlier uses this approach.

-O

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Oleg Bartunov 2004-05-31 02:48:40 Re: yet another contrib module
Previous Message Oliver Jowett 2004-05-30 22:23:47 Re: v3 protocol & string encoding