Advantage Client Engine
Return the optimization level of this AOF
UNSIGNED32 |
AdsGetAOFOptLevel ( ADSHANDLE hTable, UNSIGNED16 *pusOptLevel, UNSIGNED8 *pucNonOpt, UNSIGNED16 *pusLen ); |
hTable (I) |
Handle of a table or cursor with an AOF. |
pusOptLevel (O) |
Return the optimization level for the AOF that is on the given table. Values are ADS_OPTIMIZED_FULL, ADS_OPTIMIZED_PART, ADS_OPTIMIZED_NONE. |
pucNonOpt (O) |
Return the non-optimized portion of the filter expression in this buffer. This parameter can be NULL if only the optimization level is desired. |
pusLen (I/O) |
Length of given buffer on input, length of returned data on output. |
AdsGetAOFOptLevel returns the optimization level of the AOF expression associated with the given handle. It also returns the portion of the expression that could not be optimized. For example, if a table has a single index built on 'LASTNAME', the filter expression "LASTNAME = 'James' .and. FIRSTNAME = 'Bob'" will be partially optimized. AdsGetAOFOptLevel would return ADS_OPTIMIZED_PART for this expression, and the non-optimized portion would be "FIRSTNAME='Bob'".
Note that the optimization level returned is not affected by the resolve option (ADS_RESOLVE_IMMEDIATE or ADS_RESOLVE_DYNAMIC) that is passed to AdsSetAOF.
For more information, see Advantage Optimized Filters.