Support Questions

Find answers, ask questions, and share your expertise
Announcements
Check out our newest addition to the community, the Cloudera Data Analytics (CDA) group hub.

HBase - Use of FilterList MUST_PASS_ALL

New Contributor

Hi,

Can someone clear up how the Filter List works in HBase. My thinking was all filters much pass for the row to return, for example:

{"type":"FilterList","op":"MUST_PASS_ALL","filters":[ {"type":"SingleColumnValueFilter","op":"EQUAL","family":"ACTY","qualifier":"ACCT_ID","latestVersion":true,"comparator":{"type":"BinaryComparator","value":"C000123"}}, {"type":"SingleColumnValueFilter","op":"EQUAL","family":"ACTY","qualifier":"IP_ID","latestVersion":true,"comparator":{"type":"BinaryComparator","value":"100"}}, {"type":"SingleColumnValueFilter","op":"EQUAL","family":"ACTY","qualifier":"OFF_ID","latestVersion":true,"comparator":{"type":"BinaryComparator","value":"V00"}}, {"type":"SingleColumnValueFilter","op":"EQUAL","family":"ACTY","qualifier":"IBD_ID","latestVersion":true,"comparator":{"type":"BinaryComparator","value":"C01"}} ] }

However, in the above example, it is returning data that matches the first Value (ACCT_ID) and ignore the other constraints. What am I missing about how the query is constructed, how am I using MUST_PASS_ALL wrong?

Thanks.

1 ACCEPTED SOLUTION

Super Guru
@Stephen knott

Are filter columns part of scan? If filter columns are not part of scan then filters are ignored. Check the following link:

https://issues.apache.org/jira/browse/HBASE-4364

View solution in original post

2 REPLIES 2

Super Guru
@Stephen knott

Are filter columns part of scan? If filter columns are not part of scan then filters are ignored. Check the following link:

https://issues.apache.org/jira/browse/HBASE-4364

New Contributor

Thank you.

You are correct, I wasn't populating the Scanner object with columns, add them in:

<Scanner><column>mycolumn</column><column>mycolumn2</column><filter>...

and it works. Thanks.

Take a Tour of the Community
Don't have an account?
Your experience may be limited. Sign in to explore more.