finding a text of 2 words in wrapped content in cell from another sheet

satish78

Board Regular
Joined
Aug 31, 2014
Messages
191
Trying to find text of 2 words like city and state "dallas, TX" from sheet2 in sheet1 ColumnA(anywhere in wrapped text)

example of text in Sheet1 columnA

Robert is living in dallas, TX with his aunt.

I tried vlookup but it only search exact text in cell not somewhere in wrapped cell content/text.

Hope someone understand this query.
 

Some videos you may like

Excel Facts

Copy formula down without changing references
If you have =SUM(F2:F49) in F50; type Alt+' in F51 to copy =SUM(F2:F49) to F51, leaving the formula in edit mode. Change SUM to COUNT.

Peter_SSs

MrExcel MVP, Moderator
Joined
May 28, 2005
Messages
46,882
Office Version
  1. 365
Platform
  1. Windows
This sort of matching can be somewhat tricky/unreliable - see example below.

However, to answer your question, you could try using wildcards like this
=VLOOKUP("*dallas, TX*", ...

However, as well as (possibly) finding "Robert is living in dallas, TX with his aunt." it may instead find "Tina is living in Lake Dallas, TX with her uncle.", which of course is the wrong city.
 

satish78

Board Regular
Joined
Aug 31, 2014
Messages
191
Here I have range of "city, state"(I1:I75954) then, how can I use Wildcards in this case.
 

Peter_SSs

MrExcel MVP, Moderator
Joined
May 28, 2005
Messages
46,882
Office Version
  1. 365
Platform
  1. Windows
Here I have range of "city, state"(I1:I75954) then, how can I use Wildcards in this case.
I'm not sure how this relates to post 1?
Why not give 5-10 rows of varied dummy sample data and the expected results from that sample data?
 
Last edited:

Watch MrExcel Video

Forum statistics

Threads
1,114,111
Messages
5,546,000
Members
410,720
Latest member
SSL
Top