Comparing Text in a Cell to a Range of Text

ajwooden32

New Member
Joined
Feb 5, 2024
Messages
15
Office Version
  1. 365
Platform
  1. Windows
I'm looking for a formula to compare a range of teams in the 1st column, to a single cell of teams scheduled to play games in the 3rd column, that will provide me a list of teams with no games scheduled in the 4th column. Sometimes the teams listed under scheduled to play games are not always in order so the formula needs to be able to compare regardless of the teams order or to be able to sort then compare.

Preferably the results in the 4th column would be sorted automatically.

Thanks in advance!

TeamsDateScheduled to Play GamesNo Games Scheduled
3rd Boys A11/2/243rd Boys A, 3rd Boys B, 4th Boys A, 4th Boys B, 5th Boys A, 5th Boys B3rd Girls, 6th Boys A, 6th Boys B
3rd Boys B11/3/243rd Boys B, 4th Boys B, 5th Boys B, 6th Boys B, 6th Boys A, 6th Boys B, 3rd Boys A, 4th Boys A3rd Girls, 5th Boys A
4th Boys A11/9/245th Boys A, 5th Boys B3rd Boys A, 3rd Boys B, 3rd Girls, 4th Boys A, 4th Boys B, 6th Boys A, 6th Boys B
4th Boys B11/10/245th Boys A, 5th Boys B, 4th Boys A
5th Boys A11/16/243rd Boys A, 4th Boys A, 5th Boys A, 3rd Girls, 3rd Boys B, 4th Boys B, 5th Boys B
5th Boys B11/17/243rd Boys A, 4th Boys A, 5th Boys A, 6th Boys A, 3rd Boys B, 4th Boys B, 5th Boys B, 6th Boys B
6th Boys A
6th Boys B
3rd Girls
 

Excel Facts

Whats the difference between CONCAT and CONCATENATE?
The newer CONCAT function can reference a range of cells. =CONCATENATE(A1,A2,A3,A4,A5) becomes =CONCAT(A1:A5)
Try this:
Book1
ABCD
1TeamsDateScheduled to Play GamesNo Games Scheduled
23rd Boys A11/2/20243rd Boys A, 3rd Boys B, 4th Boys A, 4th Boys B, 5th Boys A, 5th Boys B6th Boys A, 6th Boys B, 3rd Girls
33rd Boys B11/3/20243rd Boys B, 4th Boys B, 5th Boys B, 6th Boys B, 6th Boys A, 6th Boys B, 3rd Boys A, 4th Boys A5th Boys A, 3rd Girls
44th Boys A11/9/20245th Boys A, 5th Boys B3rd Boys A, 3rd Boys B, 4th Boys A, 4th Boys B, 6th Boys A, 6th Boys B, 3rd Girls
54th Boys B########5th Boys A, 5th Boys B, 4th Boys A3rd Boys A, 3rd Boys B, 4th Boys B, 6th Boys A, 6th Boys B, 3rd Girls
65th Boys A11/16/243rd Boys A, 4th Boys A, 5th Boys A, 3rd Girls, 3rd Boys B, 4th Boys B, 5th Boys B6th Boys A, 6th Boys B
75th Boys B11/17/243rd Boys A, 4th Boys A, 5th Boys A, 6th Boys A, 3rd Boys B, 4th Boys B, 5th Boys B, 6th Boys B3rd Girls
86th Boys A
96th Boys B
103rd Girls
Sheet1
Cell Formulas
RangeFormula
D2:D7D2=TEXTJOIN(", ",1,FILTER($A$2:$A$10,ISERROR(SEARCH($A$2:$A$10&",",C2&",")),""))
 
Upvote 0
Works perfect when opened in excel. First problem solved!

1728708786947.png


Now I have a new issue. When I upload this excel file to our organization's google drive the formula that was working gives a #NAME? error now.

Any idea what's wrong with this formula & what I need to change to get it to work in google sheets?

=ARRAY_CONSTRAIN(ARRAYFORMULA(TEXTJOIN(", ",1,_xlws.FILTER($A$2:$A$13,ISERROR(SEARCH($A$2:$A$13&",",C2&",")),""))), 1, 1)

1728708768618.png
 
Upvote 0
Try change to:

Excel Formula:
=TEXTJOIN(", ",1,FILTER($A$2:$A$10,ARRAYFORMULA(ISERROR(SEARCH($A$2:$A$10&",",C2&",")))))
 
Upvote 0
Solution

Forum statistics

Threads
1,223,164
Messages
6,170,444
Members
452,326
Latest member
johnshaji

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top