How to find unique values between two columns in excel?

For example, I have two columns of different length filled with student names, and now I want to compare these two columns to select all values in column A but not in column B, and select all values in column B but not in column A. That means selecting unique values between two columns. If I compare them cell by cell, it will be very time-consuming. Are there any good ideas to find out all unique values between two columns in Excel quickly?

Find unique values between two columns with Conditional Formatting command

Find unique values between two columns with formula

Find unique values between two columns with Kutools for Excel

Recommended Productivity Software

Office Tab: Use tabbed interface in Office as the use of web browser Chrome, Firefox and Internet Explorer.
Kutools for Excel: Adds 120 powerful new features to Excel. Increase your productivity in 5 minutes. Save two hours every day!
Classic Menu for Office: Brings back your familiar menus to Office 2007, 2010 and 2013 (includes Office 365).

arrow blue right bubble Find unique values between two columns with Conditional Formatting command

Hint


Look at the following screenshot, now I will select all the values in column A but not in column C.

doc-find-unique-values1

1. Select the range of A2:A15, and then click Home > Conditional Formatting > New Rule…

doc-find-unique-values2

2. A New Formatting Rule dialog box will display. Select Use a formula to determine which cells to format from Select a Rule Type. Input this formula =ISNA(MATCH(A2,$C$2:$C$13,0)) into the Format values where this formula is true.

doc-find-unique-values3

Note: In the above formula, A2 is the column which you want to be compared. And the $C$2:$C$13 is the range that you want compared with.

3. Then click Format…button, a Format Cell dialog box will pop out, click Fill, and choose one color you like. See screenshot:

doc-find-unique-values4

4.Click OK to return to the New Formatting Rule dialog box. And click OK. Then all of the values in column A but not in column C have been selected. See screenshot:

doc-find-unique-values5

Note: with these steps, you can select the values in column A but not in column C, if you want to select the values in column C but not in column A, you can use this formula =ISNA(MATCH(C2,$A$2:$A$15,0)).


arrow blue right bubble Find unique values between two columns with formula

The following formulas also help you to find the unique values, please do as this:

1. In a blank cell B2, enter this formula =IF(ISNA(VLOOKUP(A2,$C$2:$C$13,1,FALSE)),"Yes",""), see screenshot:

doc-find-unique-values6

Note: In the above formula, A2 is the column which you want to be compared. And the $C$2:$C$13 is the range that you want compared with.

2. Then press Enter key, and select cell B2, then drag the fill handle to the cell B15. If the unique values only in column A but not in column C, it will be displayed Yes in column B. See screenshot:

doc-find-unique-values7

Note: If you want to list the unique values only in column C but not in column A, you can apply this formula: =IF(ISNA(VLOOKUP(C2,$A$2:$A$15,1,FALSE)),"Yes","").


arrow blue right bubble Find unique values between two columns with Kutools for Excel

With the Conditional Formatting command and above formulas, it is a little troublesome, and on the other hand you must remember the formula and know how to apply it. If you don’t know the formula, please don't worry, Kutools for Excel can help you to solve this task conveniently.

Kutools for Excel: with more than 120 handy Excel add-ins, free to try with no limitation in 30 days.Get it Now

If you have installed Kutools for Excel, please do as the following steps:

1. Click Kutools > Compare Ranges, see screenshot:

doc-find-unique-values8

2. In the Compare Ranges dialog box, click the first -111 button under Range A to select a range to be compared, and click the second -111 button under Range B to select the range that you want to compare with. Then select Different Values from the Rules option. See screenshot:

doc-find-unique-values9

3. Then click OK, all of the values in column A but not in column C have been selected. See screenshot:

doc-find-unique-values10

If you want to select the values in column C but not in Column A, you just need to swap the scope of Range A and Range B.


Notes:

1. My data has headers: If the data you are compared has headers, you can check this option, and the headers will not be compared.

2. Select entire rows: With this option, the entire rows which contain the same values will be selected.

3. The two comparing ranges must contain the same number of columns.

You can click here to know more about this feature.


Related article:

How to find duplicate values in two columns in Excel?


Is your problem solved?

Recommended Productivity Tools

The following tools will greatly save your time and effort, which one do you prefer?
Office Tab: Using handy tabs in your Office, as the way of Chrome, Firefox and New Internet Explorer.
Kutools for Excel: 120 powerful new functions for Excel, Increase your productivity in 5 minutes. Save two hours every day!
Classic Menu for Office: Bring back familiar menus to Office 2007, 2010, 2013 and 365, as if it were Office 2000 and 2003.

Kutools for Excel

gold star1 Amazing! Increase your productivity in 5 minutes. Don't need any special skills, save two hours every day!

gold star1 More than 120 powerful advanced functions which designed for Excel:

  • Merge Cell/Rows/Columns without Losing Data.
  • Combine and Consolidate Multiple Sheets and Workbooks.
  • Compare Ranges, Copy Multiple Ranges, Convert Text to Date, Unit and Currency Conversion.
  • Count by Colors, Paging Subtotals, Advanced Sort and Super Filter,
  • More Select/Insert/Delete/Text/Format/Link/Comment/Workbooks/Worksheets Tools...

Screen shot of Kutools for Excel

btn read more     btn download     btn purchase