pick from master #39474
This commit is contained in:
@ -816,7 +816,7 @@ public class BinaryPredicate extends Predicate implements Writable {
|
||||
return compareLiteral((LiteralExpr) leftChildValue, (LiteralExpr) rightChildValue);
|
||||
}
|
||||
|
||||
private Expr compareLiteral(LiteralExpr first, LiteralExpr second) throws AnalysisException {
|
||||
private Expr compareLiteral(LiteralExpr first, LiteralExpr second) {
|
||||
final boolean isFirstNull = (first instanceof NullLiteral);
|
||||
final boolean isSecondNull = (second instanceof NullLiteral);
|
||||
if (op == Operator.EQ_FOR_NULL) {
|
||||
@ -837,13 +837,13 @@ public class BinaryPredicate extends Predicate implements Writable {
|
||||
case EQ_FOR_NULL:
|
||||
return new BoolLiteral(compareResult == 0);
|
||||
case GE:
|
||||
return new BoolLiteral(compareResult == 1 || compareResult == 0);
|
||||
return new BoolLiteral(compareResult >= 0);
|
||||
case GT:
|
||||
return new BoolLiteral(compareResult == 1);
|
||||
return new BoolLiteral(compareResult > 0);
|
||||
case LE:
|
||||
return new BoolLiteral(compareResult == -1 || compareResult == 0);
|
||||
return new BoolLiteral(compareResult <= 0);
|
||||
case LT:
|
||||
return new BoolLiteral(compareResult == -1);
|
||||
return new BoolLiteral(compareResult < 0);
|
||||
case NE:
|
||||
return new BoolLiteral(compareResult != 0);
|
||||
default:
|
||||
|
||||
Reference in New Issue
Block a user