Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

NameError: uninitialized constant SingleColumnValueFilter

Tags:

hbase

cloudera

I am trying to use hbase filter using this code,

hbase(main):001:0> scan 'students', { FILTER => SingleColumnValueFilter.new(Bytes.toBytes('account'),Bytes.toBytes('name'), CompareFilter::CompareOp.valueOf('EQUAL'),BinaryComparator.new(Bytes.toBytes('emp1')))}

and this code give the error like, NameError: uninitialized constant SingleColumnValueFilter

Please let me know what I am doing wrong or what I need to do for get filter result.

like image 441
mohit sharma Avatar asked May 18 '26 11:05

mohit sharma


1 Answers

hbase(main):009:0> import org.apache.hadoop.hbase.util.Bytes;
    hbase(main):009:0> import org.apache.hadoop.hbase.filter.SingleColumnValueFilter;
    hbase(main):009:0> import org.apache.hadoop.hbase.filter.BinaryComparator;
    hbase(main):009:0> import org.apache.hadoop.hbase.filter.CompareFilter;
    hbase(main):009:0> import org.apache.hadoop.hbase.filter. Filter;
like image 140
mohit sharma Avatar answered May 21 '26 02:05

mohit sharma