This is an automated email from the ASF dual-hosted git repository.
dataroaring pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/doris.git
The following commit(s) were added to refs/heads/master by this push:
new d2ff68ac2d [fix](unique-key) fix query results show duplicate key for
unique key table after upgrading (#21814)
d2ff68ac2d is described below
commit d2ff68ac2d5fcbdaa282a85701e49c2cab67e8f5
Author: Xin Liao <[email protected]>
AuthorDate: Sat Jul 15 17:17:41 2023 +0800
[fix](unique-key) fix query results show duplicate key for unique key table
after upgrading (#21814)
---
be/src/olap/rowset/beta_rowset_writer.cpp | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/be/src/olap/rowset/beta_rowset_writer.cpp
b/be/src/olap/rowset/beta_rowset_writer.cpp
index 59999c1551..d99c8e9ee4 100644
--- a/be/src/olap/rowset/beta_rowset_writer.cpp
+++ b/be/src/olap/rowset/beta_rowset_writer.cpp
@@ -722,7 +722,10 @@ void
BetaRowsetWriter::_build_rowset_meta(std::shared_ptr<RowsetMeta> rowset_met
++itr) {
segments_encoded_key_bounds.push_back(*itr);
}
- if (!_is_segment_overlapping(segments_encoded_key_bounds)) {
+ // segment key bounds are empty in old version(before version 1.2.x). So
we should not modify
+ // the overlap property when key bounds are empty.
+ if (!segments_encoded_key_bounds.empty() &&
+ !_is_segment_overlapping(segments_encoded_key_bounds)) {
rowset_meta->set_segments_overlap(NONOVERLAPPING);
}
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]