0

I have a question regarding comparing lists in Excel.

Basically, I want to see if the value in column B exists in the column A for all values in column B. If the does exist, I want to Return "Yes" beside that value in column C. I have tried:

=IFERROR(IF(MATCH(B2, A2:A5000),"Yes",),"No")

But this returns "Yes" for all values, even though I know for sure that this is not the case.

Is there something that I am doing wrong?

Any assistance is appreciated.

plamut
  • 3,085
  • 10
  • 29
  • 40
Marko Dakic
  • 1
  • 1
  • 2

2 Answers2

0

Consider:

=IFERROR(IF(MATCH(B2, A2:A5000,0),"Yes",),"No")
Gary's Student
  • 95,722
  • 10
  • 59
  • 99
0

For a VBA solution that highlights duplicates and optionally spits out a list, see my answer at Good way to compare and highlight thousands of rows in VBA

jeffreyweir
  • 4,668
  • 1
  • 16
  • 27