From: Anagha Joshi <ajoshi@nulinkinc.com>
To: pgsql-hackers-owner@postgresql.org
To: pgsql-admin@postgresql.org
To: pgsql-sql@postgresql.org
Subject: URGENT : free result (libpq++ API)
Date: Thu, 21 Aug 2003 11:27:23 +0530
Message-ID: <FF851C7EEB75954F9BCFB5CA117AB1EC09289E@delta.nulinkinc.com> (raw)
Hi all,
I'm using PG - 7.2.4 on Solaries.
I'm using "libpq++" library as client implementation is coded in "C++".
I'm doing the following :
1. Making the connection to database by creating new object of
"PgDatabase" i.e.
data = new PgDatabase( " CONNECTION INFO ");
2. Then I execure the query with:
int return = data->Exec( " THIS IS A SQL QUERY");
My question is ,
How should I clear(free) the result of the query? Need I close the
connection after each query to do that?
I wish to use the same connection for multiple queries.
This problem I've observed with "libpq++" only not with "libpq" . With
"libpq" APIs the,
"PQexec" API returns "PGresult" type pointer with which we can clear
with the result of the query with "Pqclear(Pgresult *)" API.
Is the same functionality is present in "lipq++" APIs also?
Pls. help.
Thanks,
Anagha
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 from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-sql@postgresql.org
Cc: ajoshi@nulinkinc.com, pgsql-hackers-owner@postgresql.org, pgsql-admin@postgresql.org
Subject: Re: URGENT : free result (libpq++ API)
In-Reply-To: <FF851C7EEB75954F9BCFB5CA117AB1EC09289E@delta.nulinkinc.com>
References: <FF851C7EEB75954F9BCFB5CA117AB1EC09289E@delta.nulinkinc.com>
* 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