pg.ddx.io  pgsql-interfaces@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Michael Meskes <meskes@postgresql.org>
To: PostgreSQL Interfaces <pgsql-interfaces@postgresql.org>
Subject: execute immediate
Date: Wed, 13 Jun 2007 14:52:41 +0200
Message-ID: <20070613125241.GA27209@feivel.credativ.de> (raw)

According to the standard EXEC SQL EXECUTE IMMEDIATE dynamically
prepares and executes a statement. ECPG used to just simulate this by
simply executing the statement. But before rewriting this I wonder if it
makes any sense at all. Where's the advantage of preparing a statement,
then executing it and then of course deallocating it again over a simple
execution?

The EXEC SQL EXECUTE IMMEDIATE clause is needed to be able to
dynamically compute the statement to be executed, but do we really need
to prepare it?

Michael
-- 
Michael Meskes
Email: Michael at Fam-Meskes dot De, Michael at Meskes dot (De|Com|Net|Org)
ICQ: 179140304, AIM/Yahoo: michaelmeskes, Jabber: meskes@jabber.org
Go SF 49ers! Go Rhein Fire! Use Debian GNU/Linux! Use PostgreSQL!



Message-ID: <20070613125241.GA27209@feivel.credativ.de>
Permalink:  ../20070613125241.GA27209@feivel.credativ.de/
Also on:    postgresql.org/message-id/20070613125241.GA27209@feivel.credativ.de

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-interfaces@postgresql.org
  Cc: meskes@postgresql.org
  Subject: Re: execute immediate
  In-Reply-To: <20070613125241.GA27209@feivel.credativ.de>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox