TupleComparator::TupleComparator(vector<Key> const& keys, const ArrayDesc& arrayDesc): _keys(keys), _arrayDesc(arrayDesc), _leFunctions(keys.size()), _eqFunctions(keys.size()), _types(keys.size()) { for (size_t i = 0; i < _keys.size(); i++) { vector<TypeId> argTypes(2, _arrayDesc.getAttributes()[_keys[i].columnNo].getType()); FunctionDescription functionDesc; vector<FunctionPointer> converters; bool supportsVectorMode; if (!FunctionLibrary::getInstance()->findFunction("<", argTypes, functionDesc, converters, supportsVectorMode, false)) throw USER_EXCEPTION(SCIDB_SE_INTERNAL, SCIDB_LE_OPERATOR_NOT_FOUND) << "<" << argTypes[0]; _leFunctions[i] = functionDesc.getFuncPtr(); if (!FunctionLibrary::getInstance()->findFunction("=", argTypes, functionDesc, converters, supportsVectorMode, false)) throw USER_EXCEPTION(SCIDB_SE_INTERNAL, SCIDB_LE_OPERATOR_NOT_FOUND) << "=" << argTypes[0]; _eqFunctions[i] = functionDesc.getFuncPtr(); const int j = _keys[i].columnNo; TypeId strType = _arrayDesc.getAttributes()[j].getType(); _types[i] = getDoubleFloatOther(strType); } }