fix(query): set correct table number.
This commit is contained in:
parent
ae7fc15170
commit
2de2733405
|
@ -1007,14 +1007,12 @@ int32_t getTableList(void* metaHandle, void* pVnode, SScanPhysiNode* pScanNode,
|
||||||
int32_t code = TSDB_CODE_SUCCESS;
|
int32_t code = TSDB_CODE_SUCCESS;
|
||||||
size_t numOfTables = 0;
|
size_t numOfTables = 0;
|
||||||
|
|
||||||
uint64_t tableUid = pScanNode->uid;
|
|
||||||
pListInfo->suid = pScanNode->suid;
|
pListInfo->suid = pScanNode->suid;
|
||||||
|
|
||||||
SArray* pUidList = taosArrayInit(8, sizeof(uint64_t));
|
SArray* pUidList = taosArrayInit(8, sizeof(uint64_t));
|
||||||
|
|
||||||
if (pScanNode->tableType != TSDB_SUPER_TABLE) {
|
if (pScanNode->tableType != TSDB_SUPER_TABLE) {
|
||||||
if (metaIsTableExist(metaHandle, tableUid)) {
|
if (metaIsTableExist(metaHandle, pScanNode->uid)) {
|
||||||
taosArrayPush(pUidList, &tableUid);
|
taosArrayPush(pUidList, &pScanNode->uid);
|
||||||
}
|
}
|
||||||
|
|
||||||
code = doFilterByTagCond(pListInfo, pUidList, pTagCond, metaHandle);
|
code = doFilterByTagCond(pListInfo, pUidList, pTagCond, metaHandle);
|
||||||
|
@ -1042,8 +1040,10 @@ int32_t getTableList(void* metaHandle, void* pVnode, SScanPhysiNode* pScanNode,
|
||||||
} else {
|
} else {
|
||||||
// failed to find the result in the cache, let try to calculate the results
|
// failed to find the result in the cache, let try to calculate the results
|
||||||
if (pTagIndexCond) {
|
if (pTagIndexCond) {
|
||||||
SIndexMetaArg metaArg = {
|
SIndexMetaArg metaArg = {.metaEx = metaHandle,
|
||||||
.metaEx = metaHandle, .idx = tsdbGetIdx(metaHandle), .ivtIdx = tsdbGetIvtIdx(metaHandle), .suid = tableUid};
|
.idx = tsdbGetIdx(metaHandle),
|
||||||
|
.ivtIdx = tsdbGetIvtIdx(metaHandle),
|
||||||
|
.suid = pScanNode->uid};
|
||||||
|
|
||||||
SIdxFltStatus status = SFLT_NOT_INDEX;
|
SIdxFltStatus status = SFLT_NOT_INDEX;
|
||||||
code = doFilterTag(pTagIndexCond, &metaArg, pUidList, &status);
|
code = doFilterTag(pTagIndexCond, &metaArg, pUidList, &status);
|
||||||
|
|
Loading…
Reference in New Issue