zhangstar333 commented on code in PR #26160: URL: https://github.com/apache/doris/pull/26160#discussion_r1378640147
########## be/src/vec/exprs/vcompound_pred.h: ########## @@ -52,86 +54,196 @@ class VCompoundPred : public VectorizedFnCall { const std::string& expr_name() const override { return _expr_name; } Status execute(VExprContext* context, Block* block, int* result_column_id) override { - if (children().size() == 1 || !_all_child_is_compound_and_not_const() || - _children[0]->is_nullable() || _children[1]->is_nullable()) { - // TODO: - // When the child is nullable, make the optimization also take effect, and the processing of this piece may be more complicated - // https://dev.mysql.com/doc/refman/8.0/en/logical-operators.html + if (children().size() == 1 || !_all_child_is_compound_and_not_const()) { return VectorizedFnCall::execute(context, block, result_column_id); } int lhs_id = -1; int rhs_id = -1; RETURN_IF_ERROR(_children[0]->execute(context, block, &lhs_id)); - ColumnPtr lhs_column = - block->get_by_position(lhs_id).column->convert_to_full_column_if_const(); - + //should deal with const column ? Review Comment: have check the children are not const -- 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-unsubscr...@doris.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: commits-unsubscr...@doris.apache.org For additional commands, e-mail: commits-h...@doris.apache.org