Array Formula to Remove Duplicates from List

cscribner

New Member
Joined
Apr 10, 2010
Messages
3
I'm looking for help with an array formula that will condense a long list like this:

a
a
a
b
c
b
d

To this

a
b
c
d

thanks!
 

Excel Facts

Create a chart in one keystroke
Select the data and press Alt+F1 to insert a default chart. You can change the default chart to any chart type
Welcome to the board!

I agree, advanced filter is a great way to go. You might also have a look at this thread http://www.mrexcel.com/forum/showthread.php?t=435669 which has code to take in any number of lists from one or more columns, sheets or books, and spit out a single list of unique values. I have the macro from post #5 in my personal book and find it handy.
 
Upvote 0
You guys are awesome! Thanks so much--it works just the way I hoped. I'm still trying to get my head around the match function portion, which is the meat of the argument, but at least I can move forward in the meantime!
 
Upvote 0
Hi everyone

I am trying to do a similar thing Except my issue is, the function only works for numerical format or letter is fine. But if it is a text number format like "001", it wont work. Can anyone help here?
My function is this($D$11 is referencing the range of data I am filtering;F$18:F18 is the first data I found in that range):

{=IFERROR(INDEX(INDIRECT($D$11),MATCH(0,COUNTIF(INDIRECT($D$11),"<"&INDIRECT($D$11))+COUNT(INDIRECT($D$11))*ISTEXT(INDIRECT($D$11))+100000*ISBLANK(INDIRECT($D$11))-SUM(COUNTIF(INDIRECT($D$11),"="&F$18:F18)),0)),"")}
 
Upvote 0
Maybe I'm a little late to the party, but I ran across a really nice solution that uses a couple formulas to create a column that contains only the unique values from another column. It does require the use of a helper column, but you can always hide that. So far, I have tested this solution and it continues to update the values in my "duplicates" list.

Remove Duplicates or Create a List of Unique Records using Excel Formula
 
Upvote 0
Another option, if you don't mind having an extra sheet in your workbook, is to simply create a pivot table with that data set, then drag that column of data that you want condensed into a "row" on the pivot table layout. It will automatically condense it down to unique values. From there, you can just pull this list into another sheet with a simple "=" formula.
 
Upvote 0
........

I used this formula

{=IFERROR(INDEX($A$2:$A$17, MATCH(0, COUNTIF(C$1:$C1, $A$2:$A$17), 0),1),"")}

here:

http://www.mrexcel.com/forum/excel-questions/818208-code-move-vertical-horizontal-4.html?

. _ I can't remember where I got it from, but I did 'ava a go at explaining it... clourfully!

Regards
Mustava Klatsche!
 
Upvote 0
This works great,

the range you want to pull unique value / text from is the A2:A17 column; the range you want your unique value/text to be in starts at cell C2 (in the example below.



........

I used this formula

{=IFERROR(INDEX($A$2:$A$17, MATCH(0, COUNTIF(C$1:$C1, $A$2:$A$17), 0),1),"")}

here:

http://www.mrexcel.com/forum/excel-questions/818208-code-move-vertical-horizontal-4.html?

. _ I can't remember where I got it from, but I did 'ava a go at explaining it... clourfully!

Regards
Mustava Klatsche!
 
Upvote 0

Forum statistics

Threads
1,223,894
Messages
6,175,254
Members
452,624
Latest member
gregg777

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