aabujamra
aabujamra

Reputation: 4636

Lookup with partial match of strings

I have two tables:

enter image description here

enter image description here

I want to identify from which group each person in TABLE 2 is, in a way it looks like this:

enter image description here

Sample data here

Tried using lookup but didn't find my way there.

Upvotes: 1

Views: 63

Answers (1)

kishkin
kishkin

Reputation: 5325

Try this:

={
  "Solution";
  ARRAYFORMULA(
    IF(
      D4:D = "";
        "";
        VLOOKUP(
          "*" & TRIM(D4:D) & "*";
          TRIM(A5:A);
          1;
          0
        )
     )
  )
}

enter image description here

Upvotes: 2

Related Questions