Advanced filtering by "not in this column" criteria

dabenavidesd

New Member
Joined
Apr 29, 2014
Messages
11
Hi, I wanted to filter by "not in this column criteria" in boolean form ... OR ... OR like this:
Type</SPAN>Vendor</SPAN>Sales</SPAN>
<>Davolio</SPAN>
<>Buchanan</SPAN>
=Suyama</SPAN>
Type</SPAN>Vendor</SPAN>Sales</SPAN>
beverage</SPAN>Suyama</SPAN>5122 $</SPAN>
Meet</SPAN>Davolio</SPAN>450 $</SPAN>
food</SPAN>Buchanan</SPAN>6328 $</SPAN>
food</SPAN>Davolio</SPAN>6544 $</SPAN>

<TBODY>
</TBODY><COLGROUP><COL><COL><COL></COLGROUP>

And it turns out it doesn't filter anything.
Note 1: I can't make this example smaller, because it will work if I just leave 1 criteria like <>Davolio, but I want dismiss hundreds of criteria from thousand rows table.
Note 2: Actual contents of criteria tange is:
="<>Davolio"
="<>Buchanan"
="=Suyama"
Can you explain me why is this behavior ocurring?
Thanks in advance
 

Excel Facts

Difference between two dates
Secret function! Use =DATEDIF(A2,B2,"Y")&" years"&=DATEDIF(A2,B2,"YM")&" months"&=DATEDIF(A2,B2,"MD")&" days"
I think it may be the use of OR. "<>Davolio" OR "<>Buchanan" will be true for Davolio (because it doesn't equal Buchanan) and true for Buchanan (because it doesn't equal Davolio.) I'm guessing that what you want is an AND between them, which would exclude both of them?
 
Upvote 0
What do you think the result should be? ShawnPCooke has given a good explanation of using <> in an OR fashion - you get all results.

Also, you don't need the cell to be ="<>Davolio"
Just <>Davolio works. It's only equalities where you have to get creative - see the help article. Filter by using advanced criteria - Excel

Your method works, but seems to be more laborious.
 
Upvote 0
I think it may be the use of OR. "<>Davolio" OR "<>Buchanan" will be true for Davolio (because it doesn't equal Buchanan) and true for Buchanan (because it doesn't equal Davolio.) I'm guessing that what you want is an AND between them, which would exclude both of them?

Correct, that was the problem, and yes, I want to AND them, but how can I do that? By having hundreds of Vendor columns? Or is there any sort of packed formula I can write to do that, I haven't found any examples with "<>" - not equal operator. Can you enlighten me?

Thanks in advance
 
Upvote 0
To help you further, we really need to get a better understanding of what results you're looking for. Could you describe what you specifically want to include, or what you specifically want to exclude?
 
Upvote 0
To help you further, we really need to get a better understanding of what results you're looking for. Could you describe what you specifically want to include, or what you specifically want to exclude?

Yes, I want to exclude all that is in criteria column (that's to say all names listed before <> sign; I just put ="=Suyama" for illustration purposes to show I wanted to include it after applying filter), but as I said I wanted to apply the filter on thousands range list by hundreds of "not equal" range criteria for specific column, is there a way of doing this by ANDs or formula in one cell or is it need to be hundreds of those columns in the range criteria?

Thanks in advance
 
Upvote 0
Yes, I want to exclude all that is in criteria range from specified column data (that's to say names listed before <> sign; I just put ="=Suyama" for illustration purposes to show I wanted to include it after applying filter), but as I said I wanted to apply the filter on thousands list range by hundreds of "not equal" criteria range from specified column data to display only what is not shown in criteria range, is there a way of doing this by ANDs/formula in one cell or is it just need to be hundreds of those columns in the criteria range to accomplish that?

Thanks in advance
 
Upvote 0
Davolio
Buchanan
CRIT
TRUE
TypeVendorSales
beverageSuyama5122 $
MeetDavolio450 $
foodBuchanan6328 $
foodDavolio6544 $

<COLGROUP><COL style="WIDTH: 77pt; mso-width-source: userset; mso-width-alt: 3640" width=102><COL style="WIDTH: 100pt; mso-width-source: userset; mso-width-alt: 4750" width=134><COL style="WIDTH: 48pt" width=64><TBODY>
</TBODY>

A1:A2 houses a list of vendors to exclude.

A3:A4 constitutes the criteria range, where CRIT in A3 is field which does not occur as a header value in A8:C8. Leaving A3 empty is a good option.

A4 houses the following formula:

=ISNA(MATCH(B9,$A$1:$A$2,0))

A8:C12 houses the data, subject to filtering.

You just need to run Advanced Filter on A8:C18 with A3:A4 as the criteria range.
 
Upvote 0

Forum statistics

Threads
1,215,597
Messages
6,125,738
Members
449,255
Latest member
whatdoido

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top