Arbitrary Lookups with wildcard values

Z

Zargon_osu

I apologize for posting multiple subjects - I thought two problems coul
be handled separately, but they must be solved together:

I need a function to find the row number of the second cell in a colum
that meets the general requirements described by wildcard characters.

For example, I need the row of the 2nd cell in a column that meets:
AA*10*

where * is any number of characters

I was refered to "Arbitrary Lookups" using array functions, but tha
only works if I am searching for a single static value and I can't see
to get array functions to accept the wildcard tests.

Also, finding the first entry that meets the wildcard is easy using th
MATCH command, but MATCH isnt good at finding the successive entrie
after the first one.

I can do each task individually, but not together.

Any thoughts?
Thanks a to
 
H

Harlan Grove

Zargon_osu said:
I need a function to find the row number of the second cell in a column
that meets the general requirements described by wildcard characters.

For example, I need the row of the 2nd cell in a column that meets:
AA*10*

where * is any number of characters
....

If your range spanned a single column and were named List, you could try the
array formula

=INDEX(List,SMALL(IF(ISNUMBER(SEARCH("AA*10*",List)),
ROW(List)-CELL("Row",List)+1),2))

Replace the 2 with any other positive integer. To guard against the
possibility that there may not be a second (or Nth) instance matching your
text pattern, try the array formula

=IF(COUNTIF(List,"AA*10*")>=N,
INDEX(List,SMALL(IF(ISNUMBER(SEARCH("AA*10*",List)),
ROW(List)-CELL("Row",List)+1),N)),"")
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top