Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have this scenario:

  • Worksheet 1 with Column A only
  • Worksheet 2 with Column A and B

I have to compare Column A (Worksheet 1) and Column A (Worksheet 2).

If a value in Column A (Worksheet 1) is existing in Column A (Worksheet 2), it must show the value in Column B (Worksheet 2).

Please help. I have been trying to do this. I can only compare the Column A of both worksheets but I cannot show the Column B.

share|improve this question

migrated from Aug 15 '11 at 19:02

This question came from our site for professional and enthusiast programmers.

What "value" are you looking to place in column B of Sheet2? If you are looking for duplicates, you just want to list the name in column B if it's found in Sheet1? – Issun Aug 15 '11 at 10:29

This sounds like you just need a simple VLOOKUP formula.


where A2 is the value on Sheet 1 you want to look up, and A1:B20 is the entire table on Sheet2.

share|improve this answer

This means: if cell F2 is blank, return G2, else return the value of F2.

share|improve this answer

Use a simple IF formula instead.

In cell B1 enter:


and copy down as far as you need to go.

share|improve this answer

You must log in to answer this question.