Vlookup to return match within a text string

kumara_faith

Well-known Member
Joined
Aug 19, 2006
Messages
922
Office Version
  1. 365
Hi,

I have the following table:

Book1
JKLM
2Table 1Table 2
3Policy NoResultReport 1
4A45789JA45789JGHF4457IU
5G44578AN/ARTAJ77876R
6J77876RJ77876RPRMA45789J
Sheet1


In table 1, I have the policy no. I have another report in Table 2 which has the policy number within a string in the cell. Example, in cell J4, I have A45789J and in cell M6, we have PRMA45789J. I am trying to use a vlookup in column K to find a match from column M. As long as the value in column J exist within any of the string of values in column M, it should return the value in column K, otherwise to return as N/A.

Example of the correct results is in column K. Is there a way to modify the normal vlookup formula accommodate this ? Appreciate all the help.
 

Excel Facts

Formula for Yesterday
Name Manager, New Name. Yesterday =TODAY()-1. OK. Then, use =YESTERDAY in any cell. Tomorrow could be =TODAY()+1.
How about
Excel Formula:
=IF(COUNTIFS($M$4:$M$6,"*"&J4&"*"),J4,"N/A")
 
Upvote 0
Solution
Hi Fluff.

That worked. Thank you for your time and patience. Have a great day ahead .?
 
Upvote 0
You're welcome & thanks for the feedback.
 
Upvote 0

Forum statistics

Threads
1,214,840
Messages
6,121,895
Members
449,058
Latest member
Guy Boot

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