tags:

views:

63

answers:

1

i would like to do a vlookup, but i would like it to match the SUBSET of a cell. is this possible?

for example, if i am looking for "alex is smart" and the cell has "alex is smart blah blah", i want it to match on alex is smart

is this possible?

+1  A: 

You can use wildcards in the lookup value argument. If cell A1 contains the text "alex is smart" you can use:

=VLOOKUP("*"& A1 &"*",A2:B3,2,FALSE)

You can also hard-code the lookup value like:

=VLOOKUP("*alex is smart*",A2:B3,2,FALSE)
Doug Glancy
@doug: very very very cool idea!!!!!!!!!!!!! unfortunately it works only part of the time. please try it yourself on a large dataset
i am a girl
Jenny. I tried it with 20,000 rows of unique data and a match in the last row. With 10,000 rows of vlookups, it's slow, but worked. This is Excel 2003. What do you mean by "works only part of the time?" When does it work and when doesn't it?
Doug Glancy
@doug i would like to email u this file
i am a girl
Jenny, I'm sorry but I'm swamped and don't have time to pursue this. Good luck!
Doug Glancy