提交 1ac428ff 编写于 作者: A Alex Duan

fix(query): avg sum operation check range build error

上级 e9f7572a
...@@ -612,7 +612,7 @@ int32_t avgFunction(SqlFunctionCtx* pCtx) { ...@@ -612,7 +612,7 @@ int32_t avgFunction(SqlFunctionCtx* pCtx) {
for (int32_t i = pInput->startRowIndex; i < pInput->numOfRows + pInput->startRowIndex; ++i) { for (int32_t i = pInput->startRowIndex; i < pInput->numOfRows + pInput->startRowIndex; ++i) {
if (type == TSDB_DATA_TYPE_BIGINT) { if (type == TSDB_DATA_TYPE_BIGINT) {
CHECK_OVERFLOW_SUM_SIGNED(pAvgRes, plist[i]) CHECK_OVERFLOW_SUM_SIGNED(pAvgRes, plist[i])
\ } else { } else {
CHECK_OVERFLOW_SUM_UNSIGNED(pAvgRes, (uint64_t)plist[i]) CHECK_OVERFLOW_SUM_UNSIGNED(pAvgRes, (uint64_t)plist[i])
} }
} }
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册