Forum Discussion
monrobot
Sep 16, 2021Copper Contributor
HOW TO: Return multiple results if cell matches multiple table items
I'm trying to match a long string to multiple items from a table of individual items. So for example I have a cell with a value something like "Group1;Item1;User3;Group3;Item2;Group5;User1" I...
- Sep 16, 2021
Let's say that the cell with the semicolon-delimited words is A1 and that the table with individual words is in A4:A8.
Enter the following array formula in another cell, confirmed with Ctrl+Shift+Enter:
=TEXTJOIN(";",TRUE,IF(ISNUMBER(SEARCH(A4:A8,A1)),A4:A8,""))
HansVogelaar
Sep 16, 2021MVP
Let's say that the cell with the semicolon-delimited words is A1 and that the table with individual words is in A4:A8.
Enter the following array formula in another cell, confirmed with Ctrl+Shift+Enter:
=TEXTJOIN(";",TRUE,IF(ISNUMBER(SEARCH(A4:A8,A1)),A4:A8,""))
- monrobotSep 16, 2021Copper ContributorThat worked perfectly. Thanks very much!