AdsStmtSetTableLockType

Advantage Client Engine

Sets the locking type used by the statement handle

Syntax

UNSIGNED32

AdsStmtSetTableLockType( ADSHANDLE hStatement,

UNSIGNED16 usLockType )

Parameters

hStatement (I)

Handle of an SQL statement created by a call to AdsCreateSQLStatement.

usLockType (I)

Type of locking to use. Options are ADS_PROPRIETARY_LOCKING and ADS_COMPATIBLE_LOCKING. If the application is to be used with non-Advantage applications, then ADS_COMPATIBLE_LOCKING should be used. If the table will be used only by Advantage applications, then ADS_PROPRIETARY_LOCKING should be used. See Advantage Locking Modes for more information. When ADS_COMPATIBLE_LOCKING is chosen, Advantage uses the appropriate style based on the table type.

Remarks

The default value for newly created statement handles is ADS_PROPRIETARY_LOCKING.

Note There cannot be an open cursor associated with the statement when this API is called. If an open cursor exists close it using AdsCloseTable before calling this API.

Example

Click Here

See Also

AdsGetTableOpenOptions

AdsStmtSetTableCharType

AdsStmtSetTableReadOnly

AdsStmtSetTableRights

AdsStmtSetTableType