Subject Re: [IBO] LockWait seems does not work
Author Svein Erling Tysvaer
Stefano,

the instructions you quote says that it "causes the Deadlock condition",
not that it returns you a deadlock error. I would expect a LockWait
transaction to simply wait until the update conflict resolves and then do
whatever it attempted to do. Probably it just behaves as intended and
described. Or did I misunderstand what you are saying?

HTH,
Set

At 13:31 11.06.2003 +0100, you wrote:
>i'm using : Delphi 5, IBO 4 evaluation , Interbase 5.5
>
>i'm running the Test_series.dpr downloaded from
>www.ibobjects.com/docs/ti_AuditableSeries.ZIP
>
>following the instructions on the technical information shett
>*********************************************************
>Making use of Planned Deadlocks
>When the transaction goes to post the new record, it first runs through its
>Before Insert triggers and comes to the one in position 9. There, it looks
>to see if any log rows exist containing recycled invoice numbers. If so, it
>"grabs" the lowest number and performs a dummy update - SET STATUS=STATUS.
>This causes InterBase to lock the set of available rows. Because each
>user's transaction also has LockWait set to true, this causes the Deadlock
>condition for all other contenders for the lowest number. LockWait tells
>the database engine that, if a lock is encountered, the transaction wants to
>wait until the conflict goes away.
>*********************************************************
>
>i don't get any Deadlock error so i think there is something wrong in
>LockWait
>
>Any help would be appreciate
>
>Thanks in advance,
>
>Stefano Campri