Merge pull request #27881 from taosdata/fix/TD-32059-3.0

fix(query)[TD-32059]. Enable HAVING clause to work with FILL clause
This commit is contained in:
Pan Wei 2024-09-14 09:50:41 +08:00 committed by GitHub
commit 1eb298ecfd
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 4 additions and 0 deletions

View File

@ -1312,6 +1312,10 @@ static int32_t createFillLogicNode(SLogicPlanContext* pCxt, SSelectStmt* pSelect
code = createColumnByRewriteExpr(pFill->pWStartTs, &pFill->node.pTargets);
}
if (TSDB_CODE_SUCCESS == code && NULL != pSelect->pHaving) {
code = nodesCloneNode(pSelect->pHaving, &pFill->node.pConditions);
}
if (TSDB_CODE_SUCCESS == code) {
*pLogicNode = (SLogicNode*)pFill;
} else {