Solved

Vlookup - 3 collumns

Posted on 2014-04-07
5
196 Views
Last Modified: 2014-04-09
Overview

In the attached worksheet sheet 1 column A displays the list of customers. You will see there are duplicates of each customer throughout.

Sheet 2 displays the list of customers without the duplicates but also includes some other important information about each customer.

Column 'L' = customer name
Column 'M' = market category
column 'N' = rank


Question

How do I match the information for each customer on sheet two to the customer names in sheet 1.

For example I want  DRAKE TOOLING & ABR. LT      Cutting Tools      28      

to display next to every duplicate row of DRAKE TOOLING in Sheet 1.

I want to do this for every customer.

I am a complete novice to excel. I believe it would involve using the vlookup function but I have little experience of this?
Vlookup-question.xlsx
0
Comment
Question by:rob700
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
5 Comments
 
LVL 8

Accepted Solution

by:
Naresh Patel earned 500 total points
ID: 39982736
Use this formula in Sheet 1 Column B

Cell B2 =VLOOKUP(A2,Sheet2!$A$1:$C$146,2,FALSE) and copy past formula till down

& in Cell C2 =VLOOKUP(A2,Sheet2!$A$1:$C$146,3,FALSE)

Thanks
Vlookup-question.xlsx
0
 

Author Comment

by:rob700
ID: 39982771
Could you explain the process taken to come to this formula so I am able to understand and apply the process myself next time?

Thanks
Rob
0
 
LVL 8

Expert Comment

by:Naresh Patel
ID: 39982786
Sure

This is syntax for VLOOKUP Function.
VLOOKUP( value, table_array, index_number, [not_exact_match] )

Value =  value you wan tot look up in our case it is in sheet 1 - A2
Table Array = From which table you want to look up this value so it is in sheet 2 - A1:C146.
Index number = in table array which value want if look value found. in our case column number 2 & for Rating is Column number 3.
Not Exact Match = True or False, True will return to approx. match & False will return to exact match.

table array I had locked so it will remain freeze for formula drop down.

further help pls let me know. I glad to assist you.

Thanks
0
 
LVL 8

Expert Comment

by:Naresh Patel
ID: 39982794
There are many thing in VLOOKUP it self you can use combination of VLOOKUP function with MATCH. or INDEX MATCH function if lookup value is not in column number one i.e. in table selected.

I preffer you use below formula I stead of simple one.
for B2 =IFERROR(VLOOKUP($A2,Sheet2!$A$1:$C$146,MATCH(B$1,Sheet2!$A$1:$C$1,0),FALSE),"")
for C2 =IFERROR(VLOOKUP($A2,Sheet2!$A$1:$C$146,MATCH(C$1,Sheet2!$A$1:$C$1,0),FALSE),"")

As if there is any error this that will return to "" in stead of error message & you have to give header in Sheet 1 so if change header it will change its values too.

More on VLOOKUP MATCH ? I will

Thanks
0
 
LVL 1

Expert Comment

by:J2F
ID: 39986775
I like itjockey's formula for cell B2.

I would note if the values in cell B1 on Sheet 1 does not match the value in cell B1 on Sheet 2 nothing will be displayed anything since the "IFERROR" function returns TRUE and the ,"") portion of the formula is executed.

I would suggest, changing the
,"") portion of the formula in B2 to read
CHAR(34) & B$1 & CHAR(34) & " not found on sheet2!")

This will let the user know not only that something is wrong but also what is wrong.

To enter the formula for C2, just copy the formula from B2 to C2.

Jim
0

Featured Post

Online Training Solution

Drastically shorten your training time with WalkMe's advanced online training solution that Guides your trainees to action. Forget about retraining and skyrocket knowledge retention rates.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

How to get Spreadsheet Compare 2016 working with the 64 bit version of Office 2016
Access developers frequently have requirements to interact with Excel (import from or output to) in their applications.  You might be able to accomplish this with the TransferSpreadsheet and OutputTo methods, but in this series of articles I will di…
Graphs within dashboards are meant to be dynamic, representing data from a period of time that will change each time the dashboard is updated with new data. Rather than update each graph to point to a different set within a static set of data, t…
This Micro Tutorial will demonstrate how to create pivot charts out of a data set. I also added a drop-down menu which allows to choose from different categories in the data set and the chart will automatically update.

752 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question