refactor(query): add an assert.

This commit is contained in:
Haojun Liao 2022-12-12 14:28:08 +08:00
parent ba50a7c30d
commit 1d9514d6d8
1 changed files with 2 additions and 1 deletions

View File

@ -1027,9 +1027,10 @@ SResultRowPosition addToOpenWindowList(SResultRowInfo* pResultRowInfo, const SRe
int64_t* extractTsCol(SSDataBlock* pBlock, const SIntervalAggOperatorInfo* pInfo) {
TSKEY* tsCols = NULL;
if (pBlock->pDataBlock != NULL) {
if (pBlock->pDataBlock != NULL && pBlock->info.dataLoad == 1) {
SColumnInfoData* pColDataInfo = taosArrayGet(pBlock->pDataBlock, pInfo->primaryTsIndex);
tsCols = (int64_t*)pColDataInfo->pData;
ASSERT(tsCols[0] != 0);
// no data in primary ts
if (tsCols[0] == 0 && tsCols[pBlock->info.rows - 1] == 0) {