Skip site navigation (1) Skip section navigation (2)

Not clear on what PQgetResult does

From: David Rysdam <drysdam(at)ll(dot)mit(dot)edu>
To: pgsql-interfaces(at)postgresql(dot)org
Subject: Not clear on what PQgetResult does
Date: 2005-11-17 19:00:41
Message-ID: (view raw, whole thread or download thread mbox)
Lists: pgsql-interfaces
I don't understand in what sense PQgetResult is asynchronous.  Obviously 
PQsendQuery returns immediately and apparently PQgetResult() allows me 
to get separate results from multiple queries submitted together, but...

Let's say I have a table with 1,000,000 rows and I PQsendQuery() a query 
to get them all.  When I call PQgetResult() the first time, will it 
block until all 1,000,000 are ready, or will it send back everything 
that's ready at the time I call it?

If the latter, is pgtcl's pg_getresult supposed to work the same way?


pgsql-interfaces by date

Next:From: Tom LaneDate: 2005-11-17 19:38:18
Subject: Re: Not clear on what PQgetResult does
Previous:From: Goulet, DickDate: 2005-11-17 16:04:11
Subject: Re: Incremental results from libpq

Privacy Policy | About PostgreSQL
Copyright © 1996-2017 The PostgreSQL Global Development Group