Index match multiple criteria - can't understand why it doesn't work!

Ronnie12345

New Member
Joined
Mar 24, 2017
Messages
18
Hi everyone,

You would be doing me a big favour if you would explain why the following produces a #REF ! error.

The formula is simply trying to find a match of Harry and Stan to return the number 13.
QRS
2FredSmith10
3JohnJones11
4PeterBlythe12
5HarryStan13
6
7
8HarryStan
9
10#REF !
11
12INDEX(S2:S5,MATCH(Q8,Q2:Q5,0),MATCH(R8,R2:R5))

<colgroup><col width="64" span="6" style="width:48pt"> </colgroup><tbody>
</tbody>

<colgroup><col width="64" span="7" style="width:48pt"> </colgroup><tbody>
</tbody>
 

Excel Facts

Can a formula spear through sheets?
Use =SUM(January:December!E7) to sum E7 on all of the sheets from January through December
You would be doing me a big favour if you would explain why the following produces a #REF ! error.

Hi, the second parameter of the INDEX() function is the column that you want to return, so you are saying give me the value in the 4th row of the 4th column of the range S2:S5 - but there is only one column, hence the REF! error.

You could try this instead:

=INDEX(S2:S5,MATCH(1,INDEX((Q2:Q5=Q8)*(R2:R5=R8),0),0))
 
Last edited:
Upvote 0
Another one use Ctrl + Shift + Enter as it is an Array formula

=INDEX(S2:S5,MATCH(Q8&R8, Q2:Q5&R2:R5, 0))
 
Upvote 0

Forum statistics

Threads
1,215,659
Messages
6,126,077
Members
449,286
Latest member
Lantern

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