# excel sumproduct or index match

please help me get the result "e" in the attached example, either by sumproduct or index match.

Thanks
spHelp.xlsx
###### Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Commented:
Hi NPZ,

Using INDEX and MATCH, with an array formula in the MATCH portion, can return what you need. Paste the following into H6, and press control-shift-enter.
``````=INDEX(\$A\$2:\$A\$8,MATCH(F6,IF(\$C\$2:\$C\$8=G6,\$B\$2:\$B\$8),0))
``````
Matt
0
Mechanical EngineerCommented:
You could also use LOOKUP in a formula that does not need to be array-entered:
=LOOKUP(2,1/((B2:B8=F6)*(C2:C8=G6)),A2:A8)
0
Analyst Assistant Commented:
This appears to work but I'm sure it's not the best approach.

=INDEX(A2:A8,SUMPRODUCT(ROW(A2:A8)*(B2:B8=F6)*(C2:C8=G6))-1)
0

Experts Exchange Solution brought to you by

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Commented:

Very impressive use of LOOKUP, though that comes as no surprise to me. Took me 10 minutes to wrap my head around your use of the reciprocal inverse of the vector. I had no idea it could do that. Kudos!

Matt
0
Mechanical EngineerCommented:
Matt,
While you were away, we were regularly schooled by barryhoudini. That's one of his tricks, and pretty cute at that.