@Override
    public RexNode visitCall(RexCall inputCall) {
      RexNode node = super.visitCall(inputCall);
      if (node instanceof RexCall) {
        RexCall call = (RexCall) node;
        switch (call.getKind()) {
        case AND:
          return processComparisons(call, SqlKind.LESS_THAN_OR_EQUAL, false);
        case OR:
          return processComparisons(call, SqlKind.GREATER_THAN, true);
        default:
          break;
        }
      }
      return node;
    }
Transforms inequality candidates into [NOT] BETWEEN calls.
ql/src/java/org/apache/hadoop/hive/ql/optimizer/calcite/rules/HivePointLookupOptimizerRule.java