Anton Maksimenkov anton...@gmail.com writes:
I'm using libpq C Library. I prepared some query and trying to call it
many times.
But it success only at first time, and then fail with error:
... another command is already in progress
[ PQsendQuery followed by just one PQgetResult ]
IIRC, you
Anton Maksimenkov wrote:
I'm using libpq C Library. I prepared some query and trying to call it
many times.
But it success only at first time, and then fail with error:
... another command is already in progress
You are using the asynchronous queries while the testbed example program
does
On Wed, 2010-06-16 at 10:26 +0600, Anton Maksimenkov wrote:
if ((res = PQgetResult(conn)) == NULL) {
fprintf(stderr, PQgetResult() res == NULL);
PQfinish(conn);
return -1;
}
if (PQresultStatus(res) != PGRES_TUPLES_OK) {
2010/6/16 Tom Lane t...@sss.pgh.pa.us:
But it success only at first time, and then fail with error:
... another command is already in progress
[ PQsendQuery followed by just one PQgetResult ]
IIRC, you need to keep calling PQgetResult until it returns NULL
before the connection is considered
I'm using libpq C Library. I prepared some query and trying to call it
many times.
But it success only at first time, and then fail with error:
... another command is already in progress
Here is my testbed:
int
main (register int const argc, register char *const argv[])
{
PGconn