In a scan I setup a filter as follows...
final FilterList filterList = new FilterList();
final String botFilterString = getFilter(BOT_VALUE);
if (botFilterString != null)
{
m_logger.info("Bot Value Filter: " + botFilterString);
final SingleColumnValueFilter botFilter = new
SingleColumnValueFilter(TRAFFIC_FAMILY_BYTES,
BOT_VALUE.getColumnAsBytes(),
CompareFilter.CompareOp.EQUAL,
botFilterString.getBytes());
filterList.addFilter(botFilter);
}
I then add the filterList to the Scan object. The problem I am having is if I
setup a filter that I know should not return any values I still get values
returned. What is also interesting is that some of the filters work as expected
and some don't. I've had several sets of eyes look at the code and couldn't see
any obvious problems.
Thanks
-Pete
-----Original Message-----
From: Ryan Rawson [mailto:[email protected]]
Sent: Monday, January 24, 2011 3:58 PM
To: [email protected]
Subject: Re: Scan Question
CompareFilter is just an abstract base of a series of other filters
that compare specific components, what exactly are you having a
problem with?
On Mon, Jan 24, 2011 at 3:53 PM, Peter Haidinyak <[email protected]> wrote:
> That's the way I thought it should work. When I setup a filter with data that
> I know shouldn't return any data I still get rows back.
>
> -----Original Message-----
> From: Ryan Rawson [mailto:[email protected]]
> Sent: Monday, January 24, 2011 3:32 PM
> To: [email protected]
> Subject: Re: Scan Question
>
> no, if you provide a list of columns in your Scan query and a
> particular row does not actually contain _that specific column_, then
> the filter does not see anything and nothing for that row is returned.
>
> -ryan
>
> On Mon, Jan 24, 2011 at 3:20 PM, Peter Haidinyak <[email protected]> wrote:
>> If I have a table where some of the columns might not have values in each
>> row and I do a scan with a CompareFilter.CompareOp.EQUAL type filter on one
>> of those columns will the scan bring back rows where there is no value in
>> the column I am comparing on?
>
>>
>> Thanks
>>
>> -Pete
>>
>