Subject Re: [IBO] record lock
Author Helen Borrie
At 09:29 AM 18-10-01 -0700, you wrote:

>Hi all,
>Could someone tell me how to lock a record after issuing a locate command.
>I'm using an IBOTable with IB6 and D5.
>I know, it sounds stupid but I cannot find anything on record locking in
>IBO help file.

Firebird/Interbase doesn't have client locking. It uses a record multi-versioning architecture and various levels of transaction isolation with choices of lock resolution settings to achieve the protection you want.

The versioning engine in the server looks after locking. Locking is optimistic, c'est a dire, locks are not applied to a row until you actually make a change.

Perhaps you need to explain your requirement in more detail here. Possibly using the PessimisticLocking feature of the dataset will help you achieve what you want. With this setting, provided you are able to secure a lock for your located row, your transaction will "hold" that lock until you commit or roll back your transaction.

Search on PessimisticLocking in the online FAQ and also in the help file index.

There are two TechInfo papers on transactions, which you can download. These contain very complete explanations of how the isolation levels work.


All for Open and Open for All
InterBase Developer Initiative ยท