I have a list of pupil assessment results being displayed in a gallery with the source data being a collection. This list is essentially a whole year group of pupils.
I want to add add a drop down to filter the pupils for only the pupils who belong to certain pupil groups. I have called this GroupSelection

I have a Group table, with the following entries which is it's datasource:
| Group Name |
| SEN |
| EAL |
| Chorister |
I also have a 'Group Member' table which records who is in each group referencing the Group Name as a lookup field:
| Pupil Name (lookup to the pupil table) | Group Name (lookup to the Group table) |
| Bloggs, Joe | SEN |
| King, Bob | SEN |
| Scroggins, Jimmy | Chorister |
| Singalot, Gavin | Chorister |
| Outoftune, Bob | Chorister |
| Puddleduck, Jemima | EAL |
To show the current yeargoup in the gallery, on the items property I am currently using:
Filter(ResultsTable,yeargroup=yeargroupSelection.selected.text)
So from my year group list of pupils - which may contain 60 entries, I only want to show the records of the pupils in that year group who are in the selected pupil group (SEN, EAL or Chorister). How can I do this?