Comparing two columns in excel sheet

I have 3 columns
A     B     C     D
11H   3HI   xyz
2AB   2CD   dfd
3HI   11H   123
I would like to compare column A & B and if matched the adjucent cell value should be written in column D. For example
A     B     C     D
11H   3HI   xyz   123
2AB   2CD   dfd   ---
3HI   11H   123   xyz.


The formula we're after is: =VLOOKUP(A1,$B$1:$C$3,2,FALSE)
Here's an image. Always show your attempts. We tend to help those who have attempted to help themselves more.
enter image description here
However, if the dashes are a must instead of the #N/A in D2, then this is the formula =IFERROR(VLOOKUP(A3,$B$1:$C$3,2,FALSE),"---") enter image description here


Popular posts from this blog

Java Control Panel Icon "Application Not Found"

The install4j wizard could not find a Java Runtime Environment on your system. Please locate a suitable JRE...

Creating Chrome extension package in SCCM 2012