fix(query): fix error in interp
This commit is contained in:
parent
16c17bbf72
commit
96fc85017b
|
@ -206,28 +206,14 @@ static bool checkDuplicateTimestamps(STimeSliceOperatorInfo* pSliceInfo, SColumn
|
||||||
cur.pks[0].type = pPkCol->info.type;
|
cur.pks[0].type = pPkCol->info.type;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// let's discard the duplicated ts
|
||||||
if ((pSliceInfo->prevTsSet == true) && (currentTs == pSliceInfo->prevKey.ts)) {
|
if ((pSliceInfo->prevTsSet == true) && (currentTs == pSliceInfo->prevKey.ts)) {
|
||||||
// if (pPkCol == NULL) {
|
return true;
|
||||||
return true;
|
|
||||||
/* } else {
|
|
||||||
tRowGetKeyFromColData(currentTs, pPkCol, curIndex, &cur);
|
|
||||||
if (tRowKeyCompare(&cur, &pSliceInfo->prevKey) == 0) {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}*/
|
|
||||||
}
|
}
|
||||||
|
|
||||||
pSliceInfo->prevTsSet = true;
|
pSliceInfo->prevTsSet = true;
|
||||||
tRowKeyAssign(&pSliceInfo->prevKey, &cur);
|
tRowKeyAssign(&pSliceInfo->prevKey, &cur);
|
||||||
|
|
||||||
// todo handle next
|
|
||||||
if (currentTs == pSliceInfo->win.ekey && curIndex < rows - 1) {
|
|
||||||
int64_t nextTs = *(int64_t*)colDataGetData(pTsCol, curIndex + 1);
|
|
||||||
if (currentTs == nextTs) {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -735,7 +721,6 @@ static void doTimesliceImpl(SOperatorInfo* pOperator, STimeSliceOperatorInfo* pS
|
||||||
// check for duplicate timestamps
|
// check for duplicate timestamps
|
||||||
if (checkDuplicateTimestamps(pSliceInfo, pTsCol, pPkCol, i, pBlock->info.rows)) {
|
if (checkDuplicateTimestamps(pSliceInfo, pTsCol, pPkCol, i, pBlock->info.rows)) {
|
||||||
continue;
|
continue;
|
||||||
// T_LONG_JMP(pTaskInfo->env, TSDB_CODE_FUNC_DUP_TIMESTAMP);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if (checkNullRow(&pOperator->exprSupp, pBlock, i, ignoreNull)) {
|
if (checkNullRow(&pOperator->exprSupp, pBlock, i, ignoreNull)) {
|
||||||
|
@ -754,6 +739,7 @@ static void doTimesliceImpl(SOperatorInfo* pOperator, STimeSliceOperatorInfo* pS
|
||||||
if (checkWindowBoundReached(pSliceInfo)) {
|
if (checkWindowBoundReached(pSliceInfo)) {
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (checkThresholdReached(pSliceInfo, pOperator->resultInfo.threshold)) {
|
if (checkThresholdReached(pSliceInfo, pOperator->resultInfo.threshold)) {
|
||||||
saveBlockStatus(pSliceInfo, pBlock, i);
|
saveBlockStatus(pSliceInfo, pBlock, i);
|
||||||
return;
|
return;
|
||||||
|
@ -828,7 +814,6 @@ static void doTimesliceImpl(SOperatorInfo* pOperator, STimeSliceOperatorInfo* pS
|
||||||
// if reached here, meaning block processing finished naturally,
|
// if reached here, meaning block processing finished naturally,
|
||||||
// or interpolation reach window upper bound
|
// or interpolation reach window upper bound
|
||||||
pSliceInfo->pRemainRes = NULL;
|
pSliceInfo->pRemainRes = NULL;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
static void genInterpAfterDataBlock(STimeSliceOperatorInfo* pSliceInfo, SOperatorInfo* pOperator, int32_t index) {
|
static void genInterpAfterDataBlock(STimeSliceOperatorInfo* pSliceInfo, SOperatorInfo* pOperator, int32_t index) {
|
||||||
|
|
Loading…
Reference in New Issue