INDEX/MATCH with Infinite possibilites

olimajor123

Board Regular
Joined
Nov 13, 2013
Messages
72
Hi,

Was not sure what to name the topic to best describe this.

I have an INDEX, MATCH formula that looks up a list of categories to return a response time based on the category. This works fine. However I have an issue that if a person can't be allocated into a category, it automatically uses their name as the category, which presents infinite possibilities for the category name. I am looking to write into the formula something that says 'IF you can't find the category in the list, then assume the category is "Patient Moves"'

My formula is currently,

=IFERROR(INDEX(SLA!$C$3:$C$160,MATCH(Data!E2,SLA!$A$3:$A$160,0)),"")

where SLA!C is the Category to return from the table
and DATA!E is the category to look up
 

Excel Facts

Which came first: VisiCalc or Lotus 1-2-3?
Dan Bricklin and Bob Frankston debuted VisiCalc in 1979 as a Visible Calculator. Lotus 1-2-3 debuted in the early 1980's, from Mitch Kapor.
Try

=IFERROR(INDEX(SLA!$C$3:$C$160,MATCH(Data!E2,SLA!$A$3:$A$160,0)),"Patient Moves")
 
Upvote 0
You're welcome.

Strictly speaking, it's returning "Patient Moves" upon receiving ANY error. Not just the #N/A that ocurs when the match isn't found.

To be specific to that error, it would be

=IF(ISNA(MATCH(Data!E2,SLA!$A$3:$A$160,0)),"Patient Moves",INDEX(SLA!$C$3:$C$160,MATCH(Data!E2,SLA!$A$3:$A$160,0)))
 
Last edited:
Upvote 0

Forum statistics

Threads
1,215,534
Messages
6,125,374
Members
449,221
Latest member
chriscavsib

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