Share via


Api.JetGetLock 方法

明確保留更新資料列、寫入鎖定或明確防止任何其他會話更新資料列、讀取鎖定的能力。 一般而言,資料列寫入鎖定會因為更新資料列而隱含地取得。 通常不需要讀取鎖定,因為記錄版本設定。 不過,在某些情況下,交易可能會想要明確鎖定資料列以強制執行序列化,或確保後續作業會成功。

Namespace:Microsoft.Isam.Esent.Interop
裝配: Microsoft.Isam.Esent.Interop (in Microsoft.Isam.Esent.Interop.dll)

語法

'Declaration
Public Shared Sub JetGetLock ( _
    sesid As JET_SESID, _
    tableid As JET_TABLEID, _
    grbit As GetLockGrbit _
)
'Usage
Dim sesid As JET_SESID
Dim tableid As JET_TABLEID
Dim grbit As GetLockGrbitApi.JetGetLock(sesid, tableid, grbit)
public static void JetGetLock(
    JET_SESID sesid,
    JET_TABLEID tableid,
    GetLockGrbit grbit
)

參數

另請參閱

參考

Api 類別

Api 成員

Microsoft.Isam.Esent.Interop 命名空間