This is an automated email from the ASF dual-hosted git repository. kxiao pushed a commit to branch branch-2.0 in repository https://gitbox.apache.org/repos/asf/doris.git
commit b641dc5db842ea60a29e06d645768dc556a16a60 Author: huanghaibin <284824...@qq.com> AuthorDate: Sat Aug 5 09:15:38 2023 +0800 [fix](compaction) filter block row locations with delete sign should ignore merge on read scenario (#22628) --- be/src/vec/olap/vertical_block_reader.cpp | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/be/src/vec/olap/vertical_block_reader.cpp b/be/src/vec/olap/vertical_block_reader.cpp index e518f9ba8a..75d9127de2 100644 --- a/be/src/vec/olap/vertical_block_reader.cpp +++ b/be/src/vec/olap/vertical_block_reader.cpp @@ -465,8 +465,10 @@ Status VerticalBlockReader::_unique_key_next_block(Block* block, bool* eof) { filter_data[cur_row] = sign; if (UNLIKELY(!sign)) { _row_sources_buffer->set_agg_flag(row_source_idx, true); - _block_row_locations[cur_row].row_id = -1; - delete_count++; + if (UNLIKELY(_reader_context.record_rowids)) { + _block_row_locations[cur_row].row_id = -1; + delete_count++; + } } cur_row++; row_source_idx++; @@ -483,7 +485,9 @@ Status VerticalBlockReader::_unique_key_next_block(Block* block, bool* eof) { Block::filter_block(block, target_columns.size(), target_columns.size())); _stats.rows_del_filtered += block_rows - block->rows(); DCHECK(block->try_get_by_name("__DORIS_COMPACTION_FILTER__") == nullptr); - DCHECK_EQ(_block_row_locations.size(), block->rows() + delete_count); + if (UNLIKELY(_reader_context.record_rowids)) { + DCHECK_EQ(_block_row_locations.size(), block->rows() + delete_count); + } } size_t filtered_rows_in_rs_buffer = 0; --------------------------------------------------------------------- To unsubscribe, e-mail: commits-unsubscr...@doris.apache.org For additional commands, e-mail: commits-h...@doris.apache.org