The mi_qual_stratnum() accessor function

The mi_qual_stratnum() function locates a strategy function that a WHERE clause specifies in the list of strategy functions for the corresponding operator class.

Syntax

mi_integer  mi_qual_stratnum(MI_AM_QUAL_DESC *qualDesc)
qualDesc
Points to the qualification descriptor.

Usage

The return value from mi_qual_stratnum() provides an offset to retrieve the strategy function name from the key descriptor. To obtain the strategy-function name, the access method can pass the return value from mi_qual_stratnum() to the mi_key_opclass_strat() function.
Tip: The access method can alternatively use the mi_qual_funcname() function to obtain the name of a particular strategy function that the WHERE clause specifies from the qualification descriptor.

Return values

The return integer indicates the order in which the strategy function name occurs in the key descriptor. The mi_qual_stratnum() returns 0 for the first strategy function and 1 for the second strategy function name. For each subsequent strategy function, the return value increments by 1.