Re: undefined behaviour for sub-transactions?
- From: paul@xxxxxxxxx (Paul DuBois)
- Date: Mon, 14 Nov 2005 22:36:07 -0600
On 11/14/05 21:52, "Tyler MacDonald" <tyler@xxxxxx> wrote:
> I'm looking through the DBI documentation and I can't find anything about
> sub transactions (eg; if you do a "begin_work" ... "commit/rollback" when
> begin_work has already been called).
>
> This seems to work under DBD::Pg. Under DBD::mysql, I'm not sure if the
> begin_work is just being ignored, or if creating sub-transactions is the
> cause of my woes. (see http://rt.cpan.org/NoAuth/Bug.html?id=15803).
MySQL doesn't have sub-transactions (nested transactions). You can set
savepoints within a transaction and roll back to a given savepoint and then
continue the transaction from there.
>
> I think some pod on the "Transactions" heading of the DBI manpage would be
> useful, telling us what to expect (even if it is the unexpected) when we use
> sub-transactions under DBI. If this is an engine-specific thing, could DBI
> be made to be capable of figuring out whether a particular engine supports
> sub-transactions? Then any sub-begin-works could just be ignored, and, say,
> attempting to "commit" when a "rollback" has already been called could cause
> a fatal error. Or is there already some way to take care of this? There's
> very little about transactions in the DBI documentation.
>
> Thanks,
> Tyler
>
.
- References:
- undefined behaviour for sub-transactions?
- From: Tyler MacDonald
- undefined behaviour for sub-transactions?
- Prev by Date: undefined behaviour for sub-transactions?
- Next by Date: Re: undefined behaviour for sub-transactions?
- Previous by thread: undefined behaviour for sub-transactions?
- Next by thread: Re: undefined behaviour for sub-transactions?
- Index(es):
Relevant Pages
|