@Test
  public void testFilterMoreComplexVarCharColumn() throws Exception {
    //((a=pear or a<=cherry) and (b=orange)) and (c=banana or d<cherry)
    SearchArgument sarg =
        SearchArgumentFactory.newBuilder()
        .startAnd()
        .startAnd()
        .startOr()
        .equals("a", PredicateLeaf.Type.STRING, new HiveVarchar("pear", 10).toString())
        .lessThanEquals("a", PredicateLeaf.Type.STRING, new HiveVarchar("cherry", 10).toString())
        .end()
        .equals("b", PredicateLeaf.Type.STRING, new HiveVarchar("orange", 10).toString())
        .end()
        .startOr()
        .equals("c", PredicateLeaf.Type.STRING, new HiveVarchar("banana", 10).toString())
        .lessThan("d", PredicateLeaf.Type.STRING, new HiveVarchar("cherry", 10).toString())
        .end()
        .end()
        .build();
    MessageType schema = MessageTypeParser.parseMessageType("message test {" +
        " required binary a; required binary b;"
        + " required binary c; required binary d;}");

    Map<String, TypeInfo> columnTypes = new HashMap<>();
    columnTypes.put("a", TypeInfoFactory.getVarcharTypeInfo(10));
    columnTypes.put("b", TypeInfoFactory.getVarcharTypeInfo(10));
    columnTypes.put("c", TypeInfoFactory.getVarcharTypeInfo(10));
    columnTypes.put("d", TypeInfoFactory.getVarcharTypeInfo(10));

    FilterPredicate p = ParquetFilterPredicateConverter.toFilterPredicate(sarg, schema, columnTypes);
    String expected = "and(and(or(eq(a, Binary{\"pear\"}), lteq(a, Binary{\"cherry\"})), "
        + "eq(b, Binary{\"orange\"})), "
        + "or(eq(c, Binary{\"banana\"}), lt(d, Binary{\"cherry\"})))";
    assertEquals(expected, p.toString());
  }
Check the converted filter predicate is null if unsupported types are included
@throws Exception
ql/src/test/org/apache/hadoop/hive/ql/io/parquet/read/TestParquetFilterPredicate.java