FireDAC.Stan.Option.TFDUpdateOptions.LockMode

From RAD Studio API Documentation
Jump to: navigation, search

Delphi

property LockMode: TFDLockMode read GetLockMode write SetLockMode

C++

__property TFDLockMode LockMode = {read=GetLockMode, write=SetLockMode, stored=IsLMS, default=0};

Properties

Type Visibility Source Unit Parent
property published
FireDAC.Stan.Option.pas
FireDAC.Stan.Option.hpp
FireDAC.Stan.Option TFDUpdateOptions

Description

Controls how FireDAC locks a database record while editing it.

Use the LockMode property to specify the locking mode of the database record.

You can use locks to resolve a conflict of updates to the same record from different DBMS sessions. The default value is lmNone.

Mode 

Description 

lmNone

No locking at all. 

lmPessimistic

Pessimistic locking, if the DBMS supports SELECT FOR UPDATE, otherwise optimistic locking is used. If the record is locked, then FireDAC waits a certain amount of time (LockWait), if the DBMS supports lock timeout, otherwise - it depends on the DBMS settings. 

lmOptimistic

Optimistic locking. 

See Also