Comparing Values in 2 Columns

E

esta.monn

I have company names in two columns:

A A
B D
C X
D C


What I need to do is to compare values in 2nd column and if these exist
in 1st column to return name in 2nd colunn, otherwise NO MATCH
I can do this writing if statement for 1 row, but I have thousands of
rows and I need to search value from colunn 2 in all of the thousands
of rows in 1st column. Does anyone have a written IF loop statement for
this?

Thanks!!!
 
N

Niek Otten

Look at the VLOOKUP() function. Here's a tutorial:

http://www.contextures.com/xlFunctions02.html

--
Kind regards,

Niek Otten
Microsoft MVP - Excel

|I have company names in two columns:
|
| A A
| B D
| C X
| D C
|
|
| What I need to do is to compare values in 2nd column and if these exist
| in 1st column to return name in 2nd colunn, otherwise NO MATCH
| I can do this writing if statement for 1 row, but I have thousands of
| rows and I need to search value from colunn 2 in all of the thousands
| of rows in 1st column. Does anyone have a written IF loop statement for
| this?
|
| Thanks!!!
|
 
B

Biff

Hi!

suppose you have this setup:

.............A............B.............C
1..........A............A...............
2..........B............D...............
3..........C............X...............
4..........D............C...............

Enter this formula in C1 and copy down as needed:

=IF(ISNUMBER(MATCH(B1,A$1:A$4,0)),B1,"No Match")

Biff
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top