# Matching Columns

L

#### Leo

Need assistance,
I have 2 sheets in same workbook. I need to compare Column A in sheet 1 to
Column A in sheet 2 (Col A sheet1 contains a short list of data, Col A sheet2
contains longer list of data). Sheet 2 has data in Column B that matches to
Column A. If Column A sheet 1 data matches Column A sheet 2 data, I need to
display Column B sheet 2 data in Column B sheet 1.
What formula would I use?

D

#### Dave Peterson

=vlookup(a1,sheet2!a:b,2,false)
will return an error if there is no match or the value in column B of the first
match in sheet2. If column B of the first match is empty, then you'll see a 0.

You can hide the error and the 0 with a formula like:
=if(isna(vlookup(a1,sheet2!a:b,2,false)),"Missing",
if(vlookup(a1,sheet2!a:b,2,false)="","",
vlookup(a1,sheet2!a:b,2,false)))

(Change "missing" to whatever you like--including "")

J

#### jeremy

now i am sure this is simple but if i had 4 sheets and i wanted to disply the
data from column a if it showed up on more them one tab how would i do that.