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

RockandGrohl

Well-known Member
Joined
Aug 1, 2018
Messages
810
Office Version
  1. 365
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

Why are there 1,048,576 rows in Excel?
The Excel team increased the size of the grid in 2007. There are 2^20 rows and 2^14 columns for a total of 17 billion cells.
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,224,827
Messages
6,181,200
Members
453,022
Latest member
RobertV1609

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