I am looking to find a partial match between two arrays

120 Views Asked by At

I'm trying bring about a partial match result based on two arrays. One array has paragraphs that might contain words from the second array. If there is a match to one of the words in the second array, then the word (or words) should appear in the "result" column (column B in the example below. The matching words have at least the first four letter matching or else there will be too many matches. The first image is the initial state table. the one below that is the resulting table.

Initial State

Resulting state

Right now, I am using a formula that results in too many matches. I'm hoping there's one that will work for me.

=TEXTJOIN("; ",,FILTER($C$2:$C$212,ISNUMBER(SEARCH(LEFT($C$2:$C$212,4),A2))))
1

There are 1 best solutions below

0
Solar Mike On

So, try this:

enter image description here

To save you typing:

MID(A1,MAX(IFERROR(FIND($G$1:$G$3,A1,1),0)),FIND(" ",A1,MAX(IFERROR(FIND($G$1:$G$3,A1,1),0))+1)-MAX(IFERROR(FIND($G$1:$G$3,A1,1),0)))