Welcome to the MrExcel board!
Try this
Cell Formulas Range Formula B2:B5 B2 =TEXTJOIN(", ",1,FILTER(Sheet2!A$2:A$4,ISNUMBER(FIND(" "&A2&" "," "&Sheet2!B$2:B$4&" ")),""))
I even have tried this on ms excel offline does not worksSorry, no. You have asked the question in an Excel Questions forum.
I have now moved your question to the appropriate forum.