yiguolei commented on code in PR #69195:
URL: https://github.com/apache/doris/pull/69195#discussion_r4322027436
##########
be/src/storage/merger.cpp:
##########
@@ -96,6 +99,30 @@ Status set_key_range(TabletReader::ReaderParams*
reader_params, const TabletSche
return Status::OK();
}
+// Extract row locations from the rowid column and remove it from the output
block.
+Block prepare_compaction_output_block(const Block& block, int32_t
rowid_ordinal,
+ std::vector<RowLocation>* row_locations)
{
+ DORIS_CHECK_GE(rowid_ordinal, 0);
+ auto ordinal = static_cast<size_t>(rowid_ordinal);
+ DORIS_CHECK_LT(ordinal, block.columns());
+ const auto& rowid_column =
+ assert_cast<const
ColumnString&>(*block.get_by_position(ordinal).column);
+ DORIS_CHECK_EQ(rowid_column.size(), block.rows());
+ row_locations->clear();
+ row_locations->reserve(rowid_column.size());
+ for (size_t i = 0; i < rowid_column.size(); ++i) {
Review Comment:
using insert_range_from method?
--
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]