From 8ee2e40812977b5e0528ea87de63ddda0d721ee2 Mon Sep 17 00:00:00 2001 From: Yongqiang YANG <98214048+dataroaring@users.noreply.github.com> Date: Mon, 25 Sep 2023 22:32:18 +0800 Subject: [PATCH] [enhancement](zone_map_index) use direct_copy_may_cut instead of direct_copy(#24880) --- be/src/olap/rowset/segment_v2/zone_map_index.cpp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/be/src/olap/rowset/segment_v2/zone_map_index.cpp b/be/src/olap/rowset/segment_v2/zone_map_index.cpp index 9368862fff..75f0a9d845 100644 --- a/be/src/olap/rowset/segment_v2/zone_map_index.cpp +++ b/be/src/olap/rowset/segment_v2/zone_map_index.cpp @@ -91,10 +91,12 @@ template Status TypedZoneMapIndexWriter::flush() { // Update segment zone map. if (_field->compare(_segment_zone_map.min_value, _page_zone_map.min_value) > 0) { - _field->type_info()->direct_copy(_segment_zone_map.min_value, _page_zone_map.min_value); + _field->type_info()->direct_copy_may_cut(_segment_zone_map.min_value, + _page_zone_map.min_value); } if (_field->compare(_segment_zone_map.max_value, _page_zone_map.max_value) < 0) { - _field->type_info()->direct_copy(_segment_zone_map.max_value, _page_zone_map.max_value); + _field->type_info()->direct_copy_may_cut(_segment_zone_map.max_value, + _page_zone_map.max_value); } if (_page_zone_map.has_null) { _segment_zone_map.has_null = true;