Add a binary comparator that only compares up to the length of the supplied byte array --------------------------------------------------------------------------------------
Key: HBASE-2220 URL: https://issues.apache.org/jira/browse/HBASE-2220 Project: Hadoop HBase Issue Type: New Feature Components: filters Reporter: Bruno Dumon Priority: Minor Attachments: binary-prefix-comparator-patch.txt This new comparator is similar to the existing BinaryComparator, but only compares up to the length of the supplied byte array. The use-case I need this for is secondary indexes. I build a table where the row keys have the form {value}{row key}, where {value} is a fixed length byte array. On this index table I then would like to perform range scans on just the fixed length {value} part. The BinaryPrefixComparator supplied in this patch enables exactly this, when used in combination with the RowFilter. See also mail at http://mail-archives.apache.org/mod_mbox/hadoop-hbase-user/201002.mbox/%3cf5a74c8e1002100716y56371298xc96e482a6486d...@mail.gmail.com%3e -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.