Vlookup or Match help?

sherafyk

New Member
Joined
Aug 19, 2016
Messages
7
Hello, I've been trying to figure out what formula to use so that when I input it in Sheet1 column B, it looks up the string "USERID1" in column A (the url) and matches it with column A in sheet 2, and the result is the value in column B (clientName)

Sheet1
Column AColumn B
https://example.com/USERID1/randomvalues=formula for client name
https://example.com/USERID1/randomvalues=formula for client name

<tbody>
</tbody>

Sheet2
Column AColumn B
USERID1ClientName1
USERID2ClientName2

<tbody>
</tbody>

I'd appreciate any and all help. I've been at this for a few hours with no luck. Thank you!
 

Some videos you may like

Excel Facts

Can you sort left to right?
To sort left-to-right, use the Sort dialog box. Click Options. Choose "Sort left to right"

Aladin Akyurek

MrExcel MVP
Joined
Feb 14, 2002
Messages
85,201
In B2 of Sheet1 enter and copy down:

=IFERROR(LOOKUP(9.99999999999999E+307,SEARCH("/"&Sheet2!$A$2:$A$3&"/",$A2),Sheet2!$B$2:$B$3),"")
 

sherafyk

New Member
Joined
Aug 19, 2016
Messages
7
Wow, thank you so much. It works perfectly. I was dabbling with IFERROR as well but would never have thought of this. Thanks again!!!
 

Watch MrExcel Video

Forum statistics

Threads
1,123,505
Messages
5,602,062
Members
414,498
Latest member
jordanmiller7890

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
Top