Adding "SEARCH" function to this multi-criteria Index-Match

RockandGrohl

Well-known Member
Joined
Aug 1, 2018
Messages
788
Office Version
  1. 2010
Platform
  1. Windows
This is the Index Match with multiple criteria I'm using;

{=INDEX(range1,MATCH(1,(A1=range2)*(B1=range3),0))}

So two criteria. For the first criteria it's going to be a lookup value to range match, so like "Cotswold Adventure" will match with "Cotswold Adventure"

For the second criteria, it's got to match within a list. I'm trying to look up "Luton" amongst a list inside one cell that looks like this:

Code:
[TABLE="width: 565"]
<tbody>[TR]
[TD]"Oxford, Oxford Services (M40), Oxford Peartree Services (A34), Thame, Aylesbury, Leighton Buzzard, Dunstable, Luton, Stevenage, Letchworth, Cambridge"[/TD]
[/TR]
</tbody>[/TABLE]
[FONT=Verdana]


In terms of specific syntax, this is what I have, which failed:

[/FONT]
Code:
{=INDEX('[Price Panels 2019.xlsm]All Tours'!$A:$A,MATCH(1,(H2='[Price Panels 2019.xlsm]All Tours'!$C:$C)*(G2=SEARCH(G2,'[Price Panels 2019.xlsm]All Tours'!$K:$K)),0))}

Hope there is a solution. I'm aware that my search result is bringing back "111" when used on its own, instead of what I need. Maybe a nested IF?

Thanks!
 

Excel Facts

What does custom number format of ;;; mean?
Three semi-colons will hide the value in the cell. Although most people use white font instead.
Got it in the end:

Code:
{=IFERROR(INDEX(LEFT('[Price Panels 2019.xlsm]All Tours'!$A:$A,6),MATCH(1,(H2='[Price Panels 2019.xlsm]All Tours'!$C:$C)*ISNUMBER(SEARCH(G2,'[Price Panels 2019.xlsm]All Tours'!$K:$K)),0)),"")}
 
Upvote 0

Forum statistics

Threads
1,214,823
Messages
6,121,780
Members
449,049
Latest member
greyangel23

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