ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   Index / Match in formula (https://www.excelbanter.com/excel-worksheet-functions/125561-index-match-formula.html)

MRR

Index / Match in formula
 
I'm using a formula to compare two cells to an "index table" to determine a
value as follows:

=INDEX(Grid!$B$2:$CL$90,MATCH(D16,Grid!$B$2:$CL$2, 1),MATCH(D17,Grid!$B$2:$B$90,1))

My issue is that sometimes the formula works and gives me the correct value,
but sometimes it looks up "D17" on B2:CL2 and "D16" on B2:B90 -- basically
it's reversing where the match matches. Does anyone know why it does this?
I'm not finding a "method to the madness"; it's just sporadic.

Roger Govier

Index / Match in formula
 
Hi

Index expects to receive the Row co-ordinate followed by the Column
co-ordinate.
You are doing it the other way around.
Try
=INDEX(Grid!$B$2:$CL$90,MATCH(D17,Grid!$B$2:$B$90, 1),MATCH(D16,Grid!$B$2:$CL$2,1))


--
Regards

Roger Govier


"MRR" wrote in message
...
I'm using a formula to compare two cells to an "index table" to
determine a
value as follows:

=INDEX(Grid!$B$2:$CL$90,MATCH(D16,Grid!$B$2:$CL$2, 1),MATCH(D17,Grid!$B$2:$B$90,1))

My issue is that sometimes the formula works and gives me the correct
value,
but sometimes it looks up "D17" on B2:CL2 and "D16" on B2:B90 --
basically
it's reversing where the match matches. Does anyone know why it does
this?
I'm not finding a "method to the madness"; it's just sporadic.




MRR

Index / Match in formula
 
Beautiful! It worked like a charm! Thanks so much for your help!

"Roger Govier" wrote:

Hi

Index expects to receive the Row co-ordinate followed by the Column
co-ordinate.
You are doing it the other way around.
Try
=INDEX(Grid!$B$2:$CL$90,MATCH(D17,Grid!$B$2:$B$90, 1),MATCH(D16,Grid!$B$2:$CL$2,1))


--
Regards

Roger Govier


"MRR" wrote in message
...
I'm using a formula to compare two cells to an "index table" to
determine a
value as follows:

=INDEX(Grid!$B$2:$CL$90,MATCH(D16,Grid!$B$2:$CL$2, 1),MATCH(D17,Grid!$B$2:$B$90,1))

My issue is that sometimes the formula works and gives me the correct
value,
but sometimes it looks up "D17" on B2:CL2 and "D16" on B2:B90 --
basically
it's reversing where the match matches. Does anyone know why it does
this?
I'm not finding a "method to the madness"; it's just sporadic.






All times are GMT +1. The time now is 05:28 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com