Re: DBI/DBD::Pg and transactions

Поиск
Список
Период
Сортировка
От Greg Sabino Mullane
Тема Re: DBI/DBD::Pg and transactions
Дата
Msg-id 4e757c14c8b8be5e2f5d19c119ae88ae@biglumber.com
обсуждение исходный текст
Ответ на DBI/DBD::Pg and transactions  ("Roderick A. Anderson" <raanders@acm.org>)
Ответы Re: DBI/DBD::Pg and transactions  ("Roderick A. Anderson" <raanders@acm.org>)
Список pgsql-general
-----BEGIN PGP SIGNED MESSAGE-----
Hash: RIPEMD160


>Will a $sth->execute()
> of a "SELECT ... FOR UPDATE" statement allow me to update the selected
> records using
> $uth->execute( ... )
> if $sth and $uth are both created/prepared from the same database handle
> "$dbh"?

You are allowed to update either way, but the lock created by the first
execute will be in place for the second, as long as those statement handles
are from the same $dbh (database handle). In general, connecting via DBI
always gives you one connection unless you explicitly create a second one
by calling DBI->connect.

- --
Greg Sabino Mullane greg@turnstep.com
End Point Corporation
PGP Key: 0x14964AC8 200707181533
http://biglumber.com/x/web?pk=2529DF6AB8F79407E94445B4BC9B906714964AC8


-----BEGIN PGP SIGNATURE-----

iD8DBQFGnmspvJuQZxSWSsgRAxjIAJ0TRN5bTs9s1/Z3/YC/rzGdpEhWiACg11Ca
sdXpTplc1laTXywTrd+8nBw=
=5iA0
-----END PGP SIGNATURE-----



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

Предыдущее
От: Alvaro Herrera
Дата:
Сообщение: Re: monthly tally of new memberships
Следующее
От: brian
Дата:
Сообщение: Re: monthly tally of new memberships