Re: PostgreSQL locking from PHP scripts - Mailing list pgsql-php

From Alan Hodgson
Subject Re: PostgreSQL locking from PHP scripts
Date
Msg-id 200611061142.17334@hal.medialogik.com
Whole thread Raw
In response to PostgreSQL locking from PHP scripts  (Amal burman <amalburman@yahoo.com>)
List pgsql-php
On Monday 06 November 2006 11:16, "Gavin M. Roy" <gmr@ehpg.net> wrote:
> Well you can use persistent connections.  Instead of pg_connect use
> pg_pconnect.   I don't know if it will keep the lock or not, I've not
> tested, but it seems like you'd need a pretty elaborate connection
> management setup to make sure you're locking and unlocking the
> records for the right client.

No, it won't.  pconnect and connect are guaranteed to work the same by PHP,
so pconnect connections are reset at script end.  The only difference is
connection overhead.

I've been trying to find a way around this to allow cursor usage, but there
doesn't seem to be one.

--
"Thank God we don't get all the government we pay for." -- Will Rogers


Attachment

pgsql-php by date:

Previous
From: Alan Hodgson
Date:
Subject: Re: PostgreSQL locking from PHP scripts
Next
From: "Gavin M. Roy"
Date:
Subject: Re: PostgreSQL locking from PHP scripts