Vlookup Multiple Values?

AboveBeyond

Board Regular
Joined
Aug 14, 2007
Messages
114
Is Vlookup or Sumif capable of having multiple lookup values?

For example.

I want vlookup to look these values: apple, oranges, grapes

So to illustrate that in a formula (even though its wrong):
Vlookup((apples,oranges,grapes),A:B,2,false)
 

Excel Facts

Move date out one month or year
Use =EDATE(A2,1) for one month later. Use EDATE(A2,12) for one year later.
Is Vlookup or Sumif capable of having multiple lookup values?

For example.

I want vlookup to look these values: apple, oranges, grapes

So to illustrate that in a formula (even though its wrong):
Vlookup((apples,oranges,grapes),A:B,2,false)

What result do you expect to see?
 
Upvote 0
I guess it would more of a SumIF then a Vlookup.

Example:

Fruit - Cost
Apples - $10
Oranges - $25
Grapes - $5
Watermelons - $7
Berries - $2

Sumif Apples, oranges, and berries. This would equal (10+25+2) = $37.

I'm trying to find a way to create a sumif in one formula rather than putting mutliple sumif for each lookup value.
 
Upvote 0
I guess it would more of a SumIF then a Vlookup.

Example:

Fruit - Cost
Apples - $10
Oranges - $25
Grapes - $5
Watermelons - $7
Berries - $2

Sumif Apples, oranges, and berries. This would equal (10+25+2) = $37.

I'm trying to find a way to create a sumif in one formula rather than putting mutliple sumif for each lookup value.

Try...

Either:

=SUM(SUMIF($A$2:$A$7,{"Apples","Oranges","Berries"},$B$2:$B$7))

Or:

=SUMPRODUCT(SUMIF($A$2:$A$7,List,$B$2:$B$7))

where List stands for a range housing the items Apples, Oranges, and Berries.
 
Upvote 0

Forum statistics

Threads
1,214,827
Messages
6,121,823
Members
449,049
Latest member
cybersurfer5000

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