Skip to content

Commit 882e881

Browse files
Merge 3dc6696 into 7525b05
2 parents 7525b05 + 3dc6696 commit 882e881

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

ydb/core/tx/columnshard/columnshard__scan.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -253,9 +253,9 @@ class TColumnShardScan : public TActorBootstrapped<TColumnShardScan>, NArrow::IR
253253
Bytes += NArrow::GetBatchDataSize(batch);
254254
ACFL_DEBUG("stage", "data_format")("batch_size", NArrow::GetBatchDataSize(batch))("num_rows", numRows)("batch_columns", JoinSeq(",", batch->schema()->field_names()));
255255
}
256-
if (CurrentLastReadKey) {
257-
NOlap::NIndexedReader::TSortableBatchPosition pNew(result.GetLastReadKey(), 0, result.GetLastReadKey()->schema()->field_names(), {}, false);
258-
NOlap::NIndexedReader::TSortableBatchPosition pOld(CurrentLastReadKey, 0, CurrentLastReadKey->schema()->field_names(), {}, false);
256+
if (CurrentLastReadKey && ReadMetadataRanges.size() == 1) {
257+
NOlap::NIndexedReader::TSortableBatchPosition pNew(result.GetLastReadKey(), 0, result.GetLastReadKey()->schema()->field_names(), {}, ReadMetadataRanges.front()->IsDescSorted());
258+
NOlap::NIndexedReader::TSortableBatchPosition pOld(CurrentLastReadKey, 0, CurrentLastReadKey->schema()->field_names(), {}, ReadMetadataRanges.front()->IsDescSorted());
259259
AFL_VERIFY(pOld < pNew)("old", pOld.DebugJson().GetStringRobust())("new", pNew.DebugJson().GetStringRobust());
260260
}
261261
CurrentLastReadKey = result.GetLastReadKey();

0 commit comments

Comments
 (0)