Re: C Stored Function with ECPG

Tom Lane <[email protected]> Mon, 23 Feb 2009 20:47:28 -0500
Newsgroups gmane.comp.db.postgresql.interfaces
Message-ID <[email protected]>
Bob Henkel <[email protected]> writes:
> I assume it's feasible to embedd ECPG in a Postgres Stored function
> written in C?

No, I don't think so; or at least that's not the expected usage.  ECPG
expects to connect to an external server.  The normal way to issue
SQL from C-level backend code is to use the SPI interface:
http://www.postgresql.org/docs/8.3/static/spi.html

			regards, tom lane

-- 
Sent via pgsql-interfaces mailing list ([email protected])
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-interfaces