Home | Previous Page | Next Page   Descriptor Function Reference > Accessor Functions >

mi_scan_locktype()

The mi_scan_locktype() function retrieves the lock type that the database server expects for the table that am_getnext scans.

Syntax

MI_LOCK_TYPE mi_scan_locktype(MI_AM_SCAN_DESC *scanDesc);
scanDesc
points to the scan descriptor.

Usage

If the access method supports locking, use the return value from this function to determine whether you need to lock an object during am_getnext.

Return Values

MI_LCK_S indicates a shared lock on the table.

MI_LCK_X indicates an exclusive lock on the table.

MI_LCK_IS_S indicates an intent-shared lock on the table and shared lock on the row.

MI_LCK_IX_X indicates intent-exclusive lock on the table and exclusive lock on the row.

MI_LCK_SIX_X indicates an intent-shared exclusive lock on the table and an exclusive lock on the row.

Related Topics

See the descriptions of:

Home | [ Top of Page | Previous Page | Next Page | Contents | Index ]