You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@doris.apache.org by "yiguolei (via GitHub)" <gi...@apache.org> on 2023/04/12 06:31:52 UTC

[GitHub] [doris] yiguolei commented on a diff in pull request #18409: [bugfix](topn) fix topn runtime predicate crash in short circuit evaluate for types like string decimal

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


##########
be/src/olap/accept_null_predicate.h:
##########
@@ -52,8 +52,37 @@ class AcceptNullPredicate : public ColumnPredicate {
 
     uint16_t evaluate(const vectorized::IColumn& column, uint16_t* sel,
                       uint16_t size) const override {
-        LOG(FATAL) << "evaluate without flags not supported";
-        // return _nested->evaluate(column, sel, size);
+        // call nested predicate evaluate
+        uint16_t new_size = _nested->evaluate(column, sel, size);
+
+        // process NULL values
+        if (column.has_null() && new_size < size) {
+            // use a sorted set to sotre selected row idxs
+            std::set<uint16_t> selected_rows;

Review Comment:
   it may cost a lot of time to insert the null rows and selected row into the set, because it need to sort.



-- 
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: commits-unsubscribe@doris.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org