Re: [GENERAL] libpq - PQsendQuery wait for complete result

2012-11-30 Thread icholy
Albe Laurenz *EXTERN* wrote > If you have a single SQL statement, you will get only one > PQresult. You get more than one if you send a query string > with more than one statement, e.g. > > PQsendQuery(conn, "SELECT 42; SELECT 'Hello'"); > > would result in two PQresults. > > You can get multip

Re: [GENERAL] libpq - PQsendQuery wait for complete result

2012-11-30 Thread Albe Laurenz
icholy wrote: > I'm having problem with libpq's *PQexec* function hanging on intermittent > connections. > After searching around, the solution seems to be to use the asynchronous > functions *PQsendQuery*/*PQgetResult* and implement your own timeout. > > Now the issue I'm facing is that *PQgetRes

[GENERAL] libpq - PQsendQuery wait for complete result

2012-11-29 Thread icholy
I'm having problem with libpq's *PQexec* function hanging on intermittent connections. After searching around, the solution seems to be to use the asynchronous functions *PQsendQuery*/*PQgetResult* and implement your own timeout. Now the issue I'm facing is that *PQgetResult* needs to be called m