Subject Re: [firebird-support] Versioning and Row Lock
Author Ann W. Harrison
Guido Klapperich wrote:
>

> Then I totally misunderstood versioning. Let's assume, there is a record
> and Transaction 1 updates the record, but does not commit yet. Then
> Transaction 2 starts and also wants to update that record. So it gets a
> new version of the record. Now Transaction 1 commits and then
> Transaction 2 commits. So there is no deadlock and Transaction 2 wins,
> which means, the changes of Transaction 2 are the latest one. Is the
> scenario I described wrong?
>

Yes.

Transaction 2 can not update a record if the most recent version was
created by Transaction 1 and Transaction 1 is active. We don't do
dirty writes - except in read committed, and even then there are some
safeguards.

Regards,


Ann