| From: | Laurenz Albe <laurenz(dot)albe(at)cybertec(dot)at> |
|---|---|
| To: | Om Prakash Jaiswal <op12om(at)yahoo(dot)co(dot)in>, "pgsql-general(at)postgresql(dot)org" <pgsql-general(at)postgresql(dot)org> |
| Subject: | Re: Request for example using pqconnectstart,pqconnectpoll part. |
| Date: | 2021-02-04 16:16:49 |
| Message-ID: | fb71b7a9c9b6e8aecc8b52e4f3d1c3f1d7f59a8a.camel@cybertec.at |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-general |
On Thu, 2021-02-04 at 15:27 +0000, Om Prakash Jaiswal wrote:
> Please provide a sample example using pqconnectstart , pqconnectpoll to make
> a asynchronous connection and executing a query for client application in C.
> It is part of libpq - C Library.
> I am able to do query using PQconnectdb and PQexec.
> I have also used PQconnectdb and PQsendQuery. PQconnectdb is blocking call,
> now I want to replace PQconnectdb with non blocking connection pqconnectstart and pqconnectpoll.
>
> Please provide an example.
I used it in
https://github.com/laurenz/pgreplay/blob/master/database.c#L404
but it certainly is not the most concise example.
Yours,
Laurenz Albe
--
Cybertec | https://www.cybertec-postgresql.com
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Atul Kumar | 2021-02-04 17:00:20 | Re: vacuumdb not letting me connect to db |
| Previous Message | Om Prakash Jaiswal | 2021-02-04 15:27:17 | Request for example using pqconnectstart,pqconnectpoll part. |