Bruce Momjian <pgman@candle.pha.pa.us> writes:
> What would be interesting is a CREATE OR REPLACE functionality for
> prepared cursors, where you could ask for it to be prepared, but if it
> already existed, it would do nothing, or something like that.
I don't think you could call that CREATE OR REPLACE, because (if it's
supposed to be efficient) it *wouldn't* replace. In any case I think
apps would prefer to avoid the overhead of even issuing such a command.
If you approach it that way, you're adding some number of additional
SQL commands to each pooled transaction, which seems to defeat the
purpose of pre-preparing commands.
regards, tom lane