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

mi_qual_qual()

The mi_qual_qual() function points to one function or Boolean expression in a complex qualification.

Syntax

MI_AM_QUAL_DESC* mi_qual_qual(MI_AM_QUAL_DESC *qualDesc,
   mi_integer n);
qualDesc
points to the qualification descriptor.
n
identifies which qualification to retrieve in the expression.

Set n to 0 to retrieve the first qualification descriptor in the array of qualification descriptors. Set n to 1 to retrieve the second qualification descriptor in the array. Increment n by 1 to retrieve each subsequent qualification.

Usage

To determine the number of qualifications in an expression and thus the number of iterations through mi_qual_qual(), first call the mi_qual_nquals() accessor function. If mi_qual_nquals() returns 0, the access method does not call mi_qual_qual() because the access method already knows the address of the qualification descriptor. For a simple qualification, mi_qual_qual() points to the same qualification descriptor as mi_scan_quals().

If mi_qual_nquals() returns a non-zero value, the qualification descriptor combines nested qualifications in a complex expression. The access method can loop through mi_qual_qual() to process each qualification from those that AND or OR combine. For an example, refer to Processing Complex Qualifications.

Return Values

The pointer that this function returns provides the beginning address of the next qualification from a complex WHERE clause.

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