TsukiokaKogane commented on code in PR #66338:
URL: https://github.com/apache/doris/pull/66338#discussion_r3711341736
##########
be/src/storage/iterator/vcollect_iterator.cpp:
##########
@@ -501,8 +501,16 @@ Status VCollectIterator::Level0Iterator::init(bool
get_data_by_ref) {
// }
// so first child load first row and other child row_pos = -1
void VCollectIterator::Level0Iterator::init_for_union(bool get_data_by_ref) {
+ // The union path (_merge == false) always reads whole blocks via
next(Block*)
+ // or ensure_first_row_ref(), both of which require _get_data_by_ref ==
false.
+ // get_data_by_ref only makes sense on the merge path, where init()
prefetches
+ // the block view and the child is consumed row by row through the merge
heap.
+ // Honoring it here would wrongly put a multi-segment child
+ // (is_merge_iterator() == true, e.g. a table-stream scan forcing
+ // force_key_ordered_read) into by-reference mode and trip
+ // CHECK(!_get_data_by_ref). See issue #65901.
_is_merge_iterator = _rs_reader->is_merge_iterator();
- _get_data_by_ref = get_data_by_ref && _is_merge_iterator;
+ _get_data_by_ref = false;
Review Comment:
looking into it
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]