From bc2966ed8076fbdfe0f2ef4c979534824f0457c8 Mon Sep 17 00:00:00 2001 From: starocean999 <40539150+starocean999@users.noreply.github.com> Date: Thu, 29 Sep 2022 09:09:36 +0800 Subject: [PATCH] [fix](like)the dictionary column should call get_shrink_value to get correct string value (#13032) * [fix](like)the dictionary column should call get_shrink_value to get correct string value --- be/src/olap/like_column_predicate.cpp | 2 +- be/src/olap/like_column_predicate.h | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/be/src/olap/like_column_predicate.cpp b/be/src/olap/like_column_predicate.cpp index e0c9851f26..a8e91a3360 100644 --- a/be/src/olap/like_column_predicate.cpp +++ b/be/src/olap/like_column_predicate.cpp @@ -148,7 +148,7 @@ uint16_t LikeColumnPredicate::evaluate(const vectorized::IColumn& for (uint16_t i = 0; i != size; i++) { uint16_t idx = sel[i]; sel[new_size] = idx; - StringValue cell_value = nested_col_ptr->get_value(data_array[idx]); + StringValue cell_value = nested_col_ptr->get_shrink_value(data_array[idx]); unsigned char flag = 0; (_state->function)(const_cast(&_like_state), cell_value, pattern, &flag); diff --git a/be/src/olap/like_column_predicate.h b/be/src/olap/like_column_predicate.h index 662f4ee59b..2f01a4db97 100644 --- a/be/src/olap/like_column_predicate.h +++ b/be/src/olap/like_column_predicate.h @@ -152,7 +152,8 @@ private: vectorized::ColumnDictionary>(column); auto& data_array = nested_col_ptr->get_data(); for (uint16_t i = 0; i < size; i++) { - StringValue cell_value = nested_col_ptr->get_value(data_array[i]); + StringValue cell_value = + nested_col_ptr->get_shrink_value(data_array[i]); if constexpr (is_and) { unsigned char flag = 0; (_state->function)(