Multiple Vlookups

cjenkins82

New Member
Joined
Mar 3, 2016
Messages
11
I'm on 2013 and want to do multiple vlookups. I have a list of names on one sheet. i want to match that name against a list of names in several other sheets and return the value in a certain column. i.e if Joe Jones appears in sheet 1 tell me the value in column D, then repeat this for sheet 2 and sheet 3 etc. The person may not appear in every sheet but i don't want the next lookup to fail if this is the case. I have a single vlookup working but can't seem to combine. =VLOOKUP(G2|'G3'!C:O|2|0)
Thanks Charlotte
 

Excel Facts

What is the shortcut key for Format Selection?
Ctrl+1 (the number one) will open the Format dialog for whatever is selected.
You could either nest a few IFERROR formulas together until you have checked each sheet:

=IFERROR(VLOOKUP(G2,Sheet1!C:O,2,0),IFERROR(VLOOKUP(G2,Sheet2!C:O,2,0),VLOOKUP(G2,Sheet3!C:O,2,0)))

or you could try this:

=VLOOKUP(G2,INDIRECT("'"&INDEX({"Sheet1","Sheet2","Sheet3"},MATCH(1,--(COUNTIF(INDIRECT("'"&{"Sheet1","Sheet2","Sheet3"}&"'!C:C"),G2)>0),0))&"'!C:D"),2,0)

or you could type your sheet names into cells and create a named range then replace {"Sheet1","Sheet2","Sheet3"} with the name such as for example:

=VLOOKUP(G2,INDIRECT("'"&INDEX(mySheets,MATCH(1,--(COUNTIF(INDIRECT("'"&mySheets&"'!C:C"),G2)>0),0))&"'!C:D"),2,0)

Both those formulas require CTRL-SHIFT-ENTER. All depends on how many sheets you have i suppose.
 
Upvote 0
Thanks for this.....i've actually now got this formula =IFERROR(VLOOKUP(G2|'G3'!C:O|MATCH(Totals!D1|'G3'!C1:O1|0)|0)|"") but how do i replicate that formula to add the two together as i have sheet G4 too. ive tried =IFERROR(VLOOKUP(G2|'G3'!C:O|MATCH(Totals!D1|'G3'!C1:O1|0)|0)|"")|IFERROR(VLOOKUP(G2|'G4'!|MATCH(Totals!D1|'G4'!C1:O1|0)|0)|"")) but it doesnt work


You could either nest a few IFERROR formulas together until you have checked each sheet:

=IFERROR(VLOOKUP(G2,Sheet1!C:O,2,0),IFERROR(VLOOKUP(G2,Sheet2!C:O,2,0),VLOOKUP(G2,Sheet3!C:O,2,0)))

or you could try this:

=VLOOKUP(G2,INDIRECT("'"&INDEX({"Sheet1","Sheet2","Sheet3"},MATCH(1,--(COUNTIF(INDIRECT("'"&{"Sheet1","Sheet2","Sheet3"}&"'!C:C"),G2)>0),0))&"'!C:D"),2,0)

or you could type your sheet names into cells and create a named range then replace {"Sheet1","Sheet2","Sheet3"} with the name such as for example:

=VLOOKUP(G2,INDIRECT("'"&INDEX(mySheets,MATCH(1,--(COUNTIF(INDIRECT("'"&mySheets&"'!C:C"),G2)>0),0))&"'!C:D"),2,0)

Both those formulas require CTRL-SHIFT-ENTER. All depends on how many sheets you have i suppose.
 
Upvote 0
That would be like this:

=IFERROR(VLOOKUP(G2,'G3'!C:O,MATCH(Totals!D1,'G3'!C1:O1,0),0),IFERROR(VLOOKUP(G2,'G4'!C:O,MATCH(Totals!D1,'G4'!C1:O1,0),0),""))
 
Upvote 0

Forum statistics

Threads
1,224,823
Messages
6,181,181
Members
453,022
Latest member
Mohamed Magdi Tawfiq Emam

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top