yiguolei commented on code in PR #60022:
URL: https://github.com/apache/doris/pull/60022#discussion_r2703642767


##########
be/src/pipeline/exec/olap_scan_operator.cpp:
##########
@@ -895,11 +895,31 @@ Status 
OlapScanLocalState::_build_key_ranges_and_filters() {
                                 auto key = iter->first;
                                 _slot_id_to_value_range.erase(key);
 
+                                // Predicates which derive to the value range 
could be removed.
+                                // For scope value range, all predicates of 
LT/LE/GT/GE type could be removed.
+                                // For fixed value range, all predicates of 
EQ/NE/IN_LIST/NOT_IN_LIST type could be removed.
                                 std::vector<std::shared_ptr<ColumnPredicate>> 
new_predicates;
-                                for (const auto& it : 
_slot_id_to_predicates[key]) {
-                                    if (it->type() == 
PredicateType::NOT_IN_LIST ||
-                                        it->type() == PredicateType::NE) {
-                                        new_predicates.push_back(it);
+                                if (range.is_scope_value_range()) {

Review Comment:
   add beut or regression test



-- 
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]

Reply via email to