Re: PHP, PostgreSQL and transactions

Поиск
Список
Период
Сортировка
От lbayuk@mindspring.com (ljb)
Тема Re: PHP, PostgreSQL and transactions
Дата
Msg-id 9h0mo7$1er0$1@news.tht.net
обсуждение исходный текст
Список pgsql-general
nils@mbit.nl wrote:
>Hi all,
>
>I want to make use of PostgreSQL's ability of transactions in a PHP
>application. What happens when a transaction spreads over more than one
>page and a user doesn't continue the transaction?

You can't do it. Read the part in the PHP manual about what persistent
(pooled) connections really are, and what they aren't. They aren't a way
to continue a connection across mutliple page requests. For one thing,
a different web server child process is likely to handle each request.
If you are using persistent connections from PHP to PostgreSQL, you
really must make absolutely sure all transactions are closed at the
end of the page. You can use register_shutdown_function to do this.

В списке pgsql-general по дате отправления:

Предыдущее
От: Peter Eisentraut
Дата:
Сообщение: Re: postgres 7.1.2 with SuSE 7.1
Следующее
От: Ana Carolina Alonso de Armiño
Дата:
Сообщение: Re: postgres 7.1.2 with SuSE 7.1