diff --git a/src/query/src/qExecutor.c b/src/query/src/qExecutor.c index 77a402c7bef84157c6188c9482086e8f62310882..f289cea7c987b4505d16378918c8a9a9fea3ef35 100644 --- a/src/query/src/qExecutor.c +++ b/src/query/src/qExecutor.c @@ -4511,7 +4511,6 @@ int32_t doInitQInfo(SQInfo *pQInfo, STSBuf *pTsBuf, void *tsdb, int32_t vgId, bo int32_t code = TSDB_CODE_SUCCESS; SQuery *pQuery = pQInfo->runtimeEnv.pQuery; - pQuery->precision = tsdbGetCfg(tsdb)->precision; pRuntimeEnv->topBotQuery = isTopBottomQuery(pQuery); pRuntimeEnv->hasTagResults = hasTagValOutput(pQuery); @@ -6323,6 +6322,8 @@ static int32_t initQInfo(SQueryTableMsg *pQueryMsg, void *tsdb, int32_t vgId, SQ bool ret = tsBufNextPos(pTSBuf); UNUSED(ret); } + + pQuery->precision = tsdbGetCfg(tsdb)->precision; if ((QUERY_IS_ASC_QUERY(pQuery) && (pQuery->window.skey > pQuery->window.ekey)) || (!QUERY_IS_ASC_QUERY(pQuery) && (pQuery->window.ekey > pQuery->window.skey))) {