Subject | Re: [firebird-support] Re: Poor selectivity in foreign keys |
---|---|
Author | Helen Borrie |
Post date | 2004-10-16T13:18:45Z |
At 12:55 PM 16/10/2004 +0000, you wrote:
isolation. Trans2 won't be able to update or delete anything that trans1
has pending; and Trans1 on't be able to update or delete anything that
trans2 has pending.
In the case of ReadCommitted isolation, what happens depends on how the
transactions are committed - which affects both declarative RI and custom
RI triggers.
prevented from completing the second phase of two-phase commit/rollback.
Any applicable triggers - declarative RI, custom RI or other, have already
finished, whether by doing their work or by excepting.
The old and new values remain available and consistent within the
transaction that created them. They don't come into existence until the
request is posted and, once they exist, they are never affected by other
transactions.
values cease to exist.
./heLen
>If it's read committed you can only see committed values! The updateHmmm, you seem to be a bit short on your understanding of transaction
>in trans 1 isn't committed yet - so isn't visible from trans 2.
>
>Try it!
>
>I always think Firebird isolation is a bit like Relativity...
>everything depends of frames of reference!
>
>If you used proper RI and had indexes, the action in trans 2 would
>fail because it would know the value was changed in trans 1, even
>though it's not committed. Kinda like a dirty-read, but not!
isolation. Trans2 won't be able to update or delete anything that trans1
has pending; and Trans1 on't be able to update or delete anything that
trans2 has pending.
In the case of ReadCommitted isolation, what happens depends on how the
transactions are committed - which affects both declarative RI and custom
RI triggers.
>In fact it would stop you refering to both trans1.old and trans1.newIncorrect. A limbo transaction is one across multiple databases that was
>values, because both are in limbo.
prevented from completing the second phase of two-phase commit/rollback.
Any applicable triggers - declarative RI, custom RI or other, have already
finished, whether by doing their work or by excepting.
The old and new values remain available and consistent within the
transaction that created them. They don't come into existence until the
request is posted and, once they exist, they are never affected by other
transactions.
>If you commit trans1 you couldNope. Either commit or rollback ends the transaction and the new and old
>then refer to trans1.new, if you rollback trans1 you could then
>refer to trans1.old.
values cease to exist.
>This kind of magic is only possible with indexes.No kidding!!!
./heLen