Create a unique list from a column and filtering some values

mixy

New Member
Joined
Sep 15, 2012
Messages
5
Hi all,

I have created a unique list of countries using a example from this link How to extract a unique distinct list from a column in excel | Get Digital Help - Microsoft Excel resource

This is my formula array:
{=INDEX(Countries, MATCH(0, COUNTIF($K$1:K1, Countries), 0))}

where Countries is a named range for column A data. For example:
Spain
USA
USA
France
Spain

The result of the formula will be:
Spain
USA
France

Do you know how to discard, for example, Spain from the calculation?
In other words, find me the unique countries of except Spain.
In the above example, that would be USA and France

Thanks!!!

mixy
 

Some videos you may like

Excel Facts

Excel Can Read to You
Customize Quick Access Toolbar. From All Commands, add Speak Cells or Speak Cells on Enter to QAT. Select cells. Press Speak Cells.

T. Valko

Well-known Member
Joined
May 9, 2009
Messages
16,623
Hi all,

I have created a unique list of countries using a example from this link How to extract a unique distinct list from a column in excel | Get Digital Help - Microsoft Excel resource

This is my formula array:
{=INDEX(Countries, MATCH(0, COUNTIF($K$1:K1, Countries), 0))}

where Countries is a named range for column A data. For example:
Spain
USA
USA
France
Spain

The result of the formula will be:
Spain
USA
France

Do you know how to discard, for example, Spain from the calculation?
In other words, find me the unique countries of except Spain.
In the above example, that would be USA and France

Thanks!!!

mixy
Like this...

Still array enterd:

=INDEX(Countries,MATCH(0,IF(Countries<>"Spain",COUNTIF($K$1:K1,Countries)),0))
 

Teethless mama

Board Regular
Joined
Mar 31, 2007
Messages
205
=INDEX(Countries,MATCH(0,IF(Countries<>"Spain",COUNTIF(K$1:K1,Countries)),0))

Ctrl+Shift+Enter, not just Enter
copy down as far as needed
 

Watch MrExcel Video

Forum statistics

Threads
1,123,517
Messages
5,602,117
Members
414,505
Latest member
quoctrungvu99

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
Top