Hbase—— rowkey 过滤器(rowfilter)

1、RowFilter

Hbase—— rowkey 过滤器(rowfilter)

Hbase—— rowkey 过滤器(rowfilter)

提取rowkey以01结尾数据
Filter filter = new RowFilter(CompareFilter.CompareOp.EQUAL,new RegexStringComparator(".*01$"));

提取rowkey以包含201407的数据
Filter filter = new RowFilter(CompareFilter.CompareOp.EQUAL,new SubstringComparator("201407"));

提取rowkey以123开头的数据
Filter filter = new RowFilter(CompareFilter.CompareOp.EQUAL,new BinaryPrefixComparator("123".getBytes()));

上一篇:立足GitHub学编程:13个不容错过的Java项目


下一篇:Java I/O不迷茫,一文为你导航!