Thread: Multithreaded libpq?

Multithreaded libpq?

From
David George
Date:
Does libpq support multithreaded frontend apps?  I was reading in the
beginning of Chapter 2 of the Programmer's Guide that it doesn't.  I
have
an application that is portable between NT and Solaris x86 where I need
multithreaded client side access.

Thanks.
--
David George
Systems Engineer
Logical Net Corporation
http://www.logical.net

Re: Multithreaded libpq?

From
Tom Lane
Date:
David George <david@logical.net> writes:
> Does libpq support multithreaded frontend apps?

libpq is thread-ignorant.  You can use it in a multithreaded app,
but it's up to you to ensure that no two threads try to operate on
the same PQconn object at the same time.

            regards, tom lane