924060929 commented on code in PR #65821:
URL: https://github.com/apache/doris/pull/65821#discussion_r3803848347


##########
fe/fe-core/src/main/java/org/apache/doris/nereids/rules/rewrite/PushDownScoreTopNIntoOlapScan.java:
##########
@@ -195,12 +195,16 @@ private Plan pushDown(
             return null;
         }
 
+        long scoreLimit = topN.getLimit() + topN.getOffset();
+        long pushedScoreLimit = shouldDisableSearchTopN(filter.getConjuncts(), 
extractedScorePredicate)

Review Comment:
   The key is: return null (skip optimization) if no wrong result, else throw 
exception



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