Software

How to delete duplicate values and duplicate records in Excel 2007 and 2010

Using Excel 2007 and 2010, you can use the same built-in feature to to delete duplicates in columns as well as duplicate rows.

Earlier in the month, I showed you how to delete duplicates in an Excel sheet. You can use this technique in all versions of Excel. If you're using Excel 2007 or 2010, there's a built-in feature that easily removes duplicate data and duplicate records (rows).

Using the simple sheet shown below, let's remove the duplicate values from the Sold column. As you can see, the value 87 appears more than once, so let's delete the duplicates as follows:

  1. Select cells B3:B11.
  2. Click the Data tab.
  3. Click Remove Duplicates in the Data Tools group.
  4. Because you've selected a single column in a contiguous data range, Excel will ask you to confirm your selection. In this case, click the Continue With The Current Selection option, and then click Remove Duplicates.
  5. Excel will display a second dialog that shows the Sold column selected. Click OK without making any further changes.
  6. Next, Excel displays a short information message that shares the number of duplicates removed. Click OK.

You can see the results below. Excel deleted the three duplicate values and moved everything below the removed values (the value 82) up, accordingly. For this reason, you'll want to be careful how you use this feature. You'd probably not want to use this method to delete duplicate values from this particular sheet because of the displaced value.

Now, let's use this feature to delete duplicate rows. There's only one (rows 4 and 9 are the same). To delete row 9, do the following:

  1. Select A3..C11.
  2. Click the Data tab.
  3. Click Remove Duplicates in the Data Tools group.
  4. In the resulting dialog, click OK without making any changes.
  5. Click OK to confirm the change.

This time, Excel deleted only one row-row 9-and moved rows 10 and 11 up one row. When deleting rows, moving records up may be desirable. As long as you know what to expect, and you get what you expect, all is well!

About

Susan Sales Harkins is an IT consultant, specializing in desktop solutions. Previously, she was editor in chief for The Cobb Group, the world's largest publisher of technical journals.

Editor's Picks