Unsure VLOOKUP

T

tbrogdon

I have 2 worksheets. Each worksheets has a vertical list of part
numbers (1 sheet has 888 rows and the other has 956. They SHOULD be
identical part numbers on each sheet but they obviously are not. In
actuality, each page contains part numbers that don't exist on the
other.

One sheet also contains a material number associated with the part
number in the column next to the part number. The other sheet contains
a description of the part next to the part number.

I was thinking to use an IF statement and VLOOKUP to run down the part
numbers on the 2nd page and return the part descriptions to the 1st
page only to those part numbers that exist on both pages.

Unfortunately I am finding that I am in way over my head. :)

I could sure use some help.

Thanks in advance,

Tim
 
M

Max

Assume Part#, Material# are in cols A and B in Sheet1, and in Sheet2, Part#
is in col A, Part descriptions in col B. Data is presumed from row2 down in
both sheets

In Sheet1,

You could put in C2:
=IF(ISNA(MATCH(A2,Sheet2!A:A,0)),"",VLOOKUP(A2,Sheet2!A:B,2,0))
Copy C2 down to the last row of data in col A. Col C will return the Part
descriptions from Sheet2. If there's no match found for the lookup part# in
col A, it'll return blanks: "".
 
T

T. Valko

Try this:

Sheet2 PNs and Descriptions in the range A2:B1000

Sheet1 PNs and Mat Nums in the range A2:B800

Enter this formula on sheet1 in cell C2 and copy down to C800:

=IF(COUNTIF(Sheet2!A$2:A$1000,A2),VLOOKUP(A2,Sheet2!A$2:B$1000,2,0),"")

Where the formula returns a blank cell means the PN does not exist on
Sheet2.
 
T

tbrogdon

Thanks guys!

I haven't had an opportunity to implement it yet but I can already see
where I needed to adjust my logic.

Thanks again,

Tim
 

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