+ Reply to Thread
Results 1 to 5 of 5

Find array value within a string

  1. #1
    Registered User
    Join Date
    08-04-2010
    Location
    London, England
    MS-Off Ver
    Excel 2007
    Posts
    2

    Find array value within a string

    I want to FIND if a value in a table occurs within a text string.

    For example.... I have a number mulitple rows of random letters such as....

    dfgrtvghj
    utyhg
    124BVWghjj

    And my lookup table has the values

    rtv
    BVW

    These values do exist in the example above in rows 1 and 3 but not in row 2.

    So, for each row, how can I validate whether a value in my lookup table exisits within the random letters. (My lookup range is ver large so I cannot use nested FIND statements).

    Thanks
    Last edited by AULZ; 08-04-2010 at 08:54 AM.

  2. #2
    Forum Expert
    Join Date
    03-23-2004
    Location
    London, England
    MS-Off Ver
    Excel 2019
    Posts
    7,080

    Re: Find array value within a string

    Use 2 Helper columns, one for rtv one for BVW
    Use FIND or SEARCH for each inidivual string you're looking for return either TRUE or FALSE
    Copy the formula down the columns

    So your output is like

    rtv BVW
    dfgrtvghj TRUE FALSE
    utyhg FALSE FALSE
    124BVWghjj FALSE TRUE
    Regards
    Special-K

    Ensure you describe your problem clearly, I have little time available to solve these problems and do not appreciate numerous changes to them.

  3. #3
    Forum Guru DonkeyOte's Avatar
    Join Date
    10-22-2008
    Location
    Northumberland, UK
    MS-Off Ver
    O365
    Posts
    21,531

    Re: Find array value within a string

    If we assume your strings are in Col A and your table of "keywords" is say D1:D2 then

    B1: =ISNUMBER(LOOKUP(9.99E+307,SEARCH($D$1:$D$2,$A1)))
    copied down

    replace SEARCH with FIND if you require case sensitivity

  4. #4
    Registered User
    Join Date
    08-04-2010
    Location
    London, England
    MS-Off Ver
    Excel 2007
    Posts
    2

    Re: Find array value within a string

    Awesome DonkeyOte - fixed like a dream.

    Cheers

  5. #5
    Registered User
    Join Date
    08-23-2012
    Location
    Scotland
    MS-Off Ver
    Excel 2003
    Posts
    5

    Re: Find array value within a string

    FANTASATIC Donkey, just what I have been trawling the net for! Never thought that formula was going to work with the numbers in the lookup, not sure what it is doing, but it works a treat!

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1