提交 ad45c0a8 编写于 作者: H Haojun Liao

fix(query): set the group id.

上级 60574763
......@@ -800,9 +800,15 @@ int32_t getTableList(void* metaHandle, void* pVnode, SScanPhysiNode* pScanNode,
taosMemoryFreeClear(pColInfoData);
}
for (int i = 0; i < taosArrayGetSize(res); i++) {
size_t numOfTables = taosArrayGetSize(res);
for (int i = 0; i < numOfTables; i++) {
STableKeyInfo info = {.uid = *(uint64_t*)taosArrayGet(res, i), .groupId = 0};
taosArrayPush(pListInfo->pTableList, &info);
void* p = taosArrayPush(pListInfo->pTableList, &info);
if (p == NULL) {
taosArrayDestroy(res);
return TSDB_CODE_OUT_OF_MEMORY;
}
qDebug("tagfilter get uid:%ld", info.uid);
}
......
......@@ -4998,7 +4998,12 @@ static void doMergeAlignedIntervalAgg(SOperatorInfo* pOperator) {
break;
}
if (pMiaInfo->groupId != pBlock->info.groupId && pMiaInfo->groupId != 0) {
if (pMiaInfo->groupId == 0) {
if (pMiaInfo->groupId != pBlock->info.groupId) {
pMiaInfo->groupId = pBlock->info.groupId;
}
} else {
if (pMiaInfo->groupId != pBlock->info.groupId) {
// if there are unclosed time window, close it firstly.
ASSERT(pMiaInfo->curTs != INT64_MIN);
finalizeResultRows(pIaInfo->aggSup.pResultBuf, &pResultRowInfo->cur, pSup, pRes, pTaskInfo);
......@@ -5007,6 +5012,9 @@ static void doMergeAlignedIntervalAgg(SOperatorInfo* pOperator) {
pMiaInfo->curTs = INT64_MIN;
pMiaInfo->groupId = 0;
break;
} else {
// continue
}
}
getTableScanInfo(pOperator, &pIaInfo->inputOrder, &scanFlag);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册