diff --git a/source/libs/parser/src/parTranslater.c b/source/libs/parser/src/parTranslater.c index c5fe3a1f73314eff38f33ebe683cf0692f0c6efa..486d7ab26cd7c83c10a1b145fa027888c8f51a76 100644 --- a/source/libs/parser/src/parTranslater.c +++ b/source/libs/parser/src/parTranslater.c @@ -1523,9 +1523,9 @@ static int32_t translateInterpFunc(STranslateContext* pCxt, SFunctionNode* pFunc SSelectStmt* pSelect = (SSelectStmt*)pCxt->pCurrStmt; SNode* pTable = pSelect->pFromTable; - if ((NULL != pTable && QUERY_NODE_REAL_TABLE != nodeType(pTable))) { + if (NULL != pTable && QUERY_NODE_REAL_TABLE != nodeType(pTable) && QUERY_NODE_TEMP_TABLE != nodeType(pTable)) { return generateSyntaxErrMsgExt(&pCxt->msgBuf, TSDB_CODE_PAR_ONLY_SUPPORT_SINGLE_TABLE, - "%s is only supported in single table query", pFunc->functionName); + "unsupported table type for %s query", pFunc->functionName); } if (pSelect->hasAggFuncs || pSelect->hasMultiRowsFunc || pSelect->hasIndefiniteRowsFunc) {