Removing duplicates

  • Thread starter Thread starter Randy
  • Start date Start date
R

Randy

I have a 2 column spreadsheet...where column a is a person's name, and
column b is their email addy. I want to identify duplicate emails,
and then remove the email with the associated name. I *think* I can
identify the dupes...but have no idea how to tell the program to
delete the duplicate *with* the associated name from column a.

Any help would be greatly appreciated.
 
Excel won't delete rows on its own. You would need a VBA macro to do that.
But, assuming this is a one-time chore, you don't need VBA. Use a helper
column. Assuming you have headers in row 1, in C2 put this formula:

=IF(COUNTIF(B$2:B2,B2)>1,1,0)

Copy that down as far as needed. Then AutoFilter on column C, displaying the
1's. Then select the visible rows and delete them. Then remove the filter and
delete column C.
 
Select the list that contains duplicates and use the Data -
Filter -> Advanced Filter option. In the pop-up window,
select the "Unique records only" checkbox. The rest of the
inputs are straight-forward.
-----Original Message-----
Excel won't delete rows on its own. You would need a VBA macro to do that.
But, assuming this is a one-time chore, you don't need VBA. Use a helper
column. Assuming you have headers in row 1, in C2 put this formula:

=IF(COUNTIF(B$2:B2,B2)>1,1,0)

Copy that down as far as needed. Then AutoFilter on column C, displaying the
1's. Then select the visible rows and delete them. Then remove the filter and
delete column C.
 
Back
Top