Multple Column Search - 1x text within text search + match - excel formula

Froggy74

New Member
Joined
Mar 13, 2019
Messages
2
Hi All,
I am struggling and need the brains of this forum to help me please.

I am looking for an excel formula that can search multiple columns in a range of data and return an answer in the third column. The difficulty I am having is 1 criteria requires searching for specific text in an email address (so not the whole email) and then combine with their LAST Name to return a user code.
I have provided an example data set (the actual data set is 50,000 lines long)

Code LAST FIRST EMAIL
ABC Doe Jon jondoe@xyz.us
BBC Smith Granny snowysmith@xyz.us
CBC Day Happy snowy.a.day@xyz.us

The criteria I have is a user called "Snowy" last name "Day". However their formal first name is not "Snowy" but "Happy". What I am trying to return is Code CBC.

I am looking for an excel formula (akin to an array index match formula) that can match "snowy" from the email and Day from the Last name to give me the CBC code.

Can anyone help?
 

Excel Facts

Square and cube roots
The =SQRT(25) is a square root. For a cube root, use =125^(1/3). For a fourth root, use =625^(1/4).
Welcome to the Board!

Try:

Excel 2012
ABCDEFGH
1CodeLASTFIRSTEMAILLast NameEmail part
2ABCDoeJonjondoe@xyz.usDaysnowy
3BBCSmithGrannysnowysmith@xyz.us
4CBCDayHappysnowy.a.day@xyz.us# of matchesFirst match
51CBC

<colgroup><col style="width: 25pxpx"><col><col><col><col><col><col><col><col></colgroup><thead>
</thead><tbody>
</tbody>
Sheet4

Worksheet Formulas
CellFormula
G5=COUNTIFS(B:B,G2,D:D,"*"&H2&"*")

<thead>
</thead><tbody>
</tbody>

<tbody>
</tbody>

Array Formulas
CellFormula
H5{=IFERROR(INDEX(A:A,SMALL(IF(B2:B100=G2,IF(ISNUMBER(SEARCH(H2,D2:D100)),ROW(B2:B100))),1)),"no match")}

<thead>
</thead><tbody>
</tbody>
Entered with Ctrl+Shift+Enter. If entered correctly, Excel will surround with curly braces {}.
Note: Do not try and enter the {} manually yourself

<tbody>
</tbody>
 
Upvote 0

Forum statistics

Threads
1,215,034
Messages
6,122,782
Members
449,095
Latest member
m_smith_solihull

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