fix: output datablcok desc error

This commit is contained in:
Xiaoyu Wang 2022-08-12 17:08:32 +08:00
parent dc991a9040
commit 2ad70dff1e
2 changed files with 4 additions and 1 deletions

View File

@ -195,7 +195,7 @@ static int32_t addDataBlockSlotsImpl(SPhysiPlanContext* pCxt, SNodeList* pList,
int32_t code = TSDB_CODE_SUCCESS;
SHashObj* pHash = taosArrayGetP(pCxt->pLocationHelper, pDataBlockDesc->dataBlockId);
int16_t nextSlotId = taosHashGetSize(pHash), slotId = 0;
int16_t nextSlotId = LIST_LENGTH(pDataBlockDesc->pSlots), slotId = 0;
SNode* pNode = NULL;
FOREACH(pNode, pList) {
SNode* pExpr = QUERY_NODE_ORDER_BY_EXPR == nodeType(pNode) ? ((SOrderByExprNode*)pNode)->pExpr : pNode;

View File

@ -48,6 +48,9 @@ TEST_F(PlanIntervalTest, fill) {
run("SELECT _WSTART, TBNAME, COUNT(*) FROM st1 "
"WHERE ts > '2022-04-01 00:00:00' and ts < '2022-04-30 23:59:59' "
"PARTITION BY TBNAME INTERVAL(10s) FILL(PREV)");
run("SELECT COUNT(c1), MAX(c3), COUNT(c1) FROM t1 "
"WHERE ts > '2022-04-01 00:00:00' and ts < '2022-04-30 23:59:59' INTERVAL(10s) FILL(PREV)");
}
TEST_F(PlanIntervalTest, selectFunc) {