From: Richard Jones <rich@annexia.org>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: pgsql-interfaces@postgresql.org
Subject: Re: Parse a statement, get parameter types and return types
Date: Mon, 18 Jul 2005 18:01:14 +0100
Message-ID: <20050718170113.GA3411@furbychan.cocan.org> (raw)
In-Reply-To: <2839.1121695124@sss.pgh.pa.us>
References: <20050718130337.GA23201@furbychan.cocan.org>
<2839.1121695124@sss.pgh.pa.us>
On Mon, Jul 18, 2005 at 09:58:44AM -0400, Tom Lane wrote:
> This is possible at the protocol level -- see Describe Statement.
> I'm not sure which client libraries let you get at the results ...
> libpq isn't one of them :-(
Thanks for answering my question so promptly!
I've made a small patch against 8.0.3 which adds this functionality to
libpq-fe. However I am not very certain of how the asynchronous stuff
works in this library, so it will need careful checking.
Nevertheless, it Works For Me in the limited testing I have done
against a 7.4 server.
http://annexia.org/tmp/PQsendDescribeStatement.diff
Note the user is expected to free(3) the Oids (types) array returned
by PQgetDescription.
Rich.
--
Richard Jones, CTO Merjis Ltd.
Merjis - web marketing and technology - http://merjis.com
Team Notepad - intranets and extranets for business - http://team-notepad.com
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: rich@annexia.org, tgl@sss.pgh.pa.us
Subject: Re: Parse a statement, get parameter types and return types
In-Reply-To: <20050718170113.GA3411@furbychan.cocan.org>
* 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