This function compares the value(s) referenced by the current position of the index cursor with value(s) supplied by the application.
MCO_RET classname_indexname_compare( /*IN*/ mco_trans_h trans, /*IN*/ mco_cursor_h cursor, /*IN*/ [const] <type> [*]param1, [[/*IN*/ uint2 len1,] [/*IN*/ [const] <type> [*]param2, [/*IN*/ uint2 len2,] ...], /*OUT*/ int *result);
trans
mco_trans_start().cursor
classname_indexname_index_cursor().param1
type, where type is the data type of the classname.fieldname component of the index. If the index component is char or string, the param is a const char *.len1
param1 is a char or string, len1 specifies the length of the input buffer.param2
len2
param2 thru paramN are char or string, each such parameter argument is followed by a lenN parameter to specify the length of the paramN buffer.result
This function compares the value(s) referenced by the current position of the index cursor with value(s) supplied by the application. It can be used to affect range-based retrievals. This function is only generated for tree indexes, and not for hash indexes.
MCO_S_OK
MCO_E_VOLUNTARY_NOT_EXIST
indexname is voluntary and has not been created, or was dropped.MCO_E_CURSOR_INVALID