Re: Accessing a database via AJAX scripts - Mailing list pgsql-general

From Glen Eustace
Subject Re: Accessing a database via AJAX scripts
Date
Msg-id 4C5F1CD0.4040805@godzone.net.nz
Whole thread Raw
In response to Re: Accessing a database via AJAX scripts  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: Accessing a database via AJAX scripts
List pgsql-general
> Not on that much evidence; but trying to pass a libpq connection across
> a fork is usually risky.  The trouble is that both parent and child
> processes now hold copies of the open socket connection, but only one of
> them can safely work with it.  It could be that you've closed the libpq
> connection in one process and that killed its usability in the other.


Thanks Tom, that is pretty much the conclusion I came to.  I think I
need to close the db connection prior to the fork and then re-open in
the new child.

--
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
Glen and Rosanne Eustace
GodZone Internet Services, a division of AGRE Enterprises Ltd.
P.O. Box 8020, Palmerston North, New Zealand 4446.
Ph: +64 6 357 8168, Fax +64 6 357 8165, Mob: +64 27 542 4015
http://www.godzone.net.nz

"A Ministry specialising in providing low-cost Internet Services
to NZ Christian Churches, Ministries and Organisations."

pgsql-general by date:

Previous
From: Jose Maria Terry
Date:
Subject: Re: Help with select with max and min please
Next
From: David Fetter
Date:
Subject: Re: Using AND in query