Hi Sophie Macleod,
It is not possible with default drop-down filters in the datagrid, but you achieve it by creating a data grid with custom filters.
You can follow this woderful post : https://medium.com/mendix/create-your-own-way-of-filter-by-npe-non-persistant-entity-and-microflow-4ffd11e52fb0
You can make use of the Selectable object in the Reference Selector, if you are using Mendix 10 you can make use of the Combo Box widget for more powerful filter features.
ATB!!
This is one way that might work (note, this uses view entities which are beta in 10.19):
This data grid has 3 cascading drop-downs - first you select country, then the cities in that country, then a relevant zip code:
The grid will show all customers that have a delivery address that matched (part of) the selection
The filter section uses an NPE with your filter settings:
The cascading drop-down use a view entity to query the data for the dropdown:
Every dropdown is filtered by the previous dropdown selection:
The data grid filters by these NPE selections:
The grid itself has a view entity as datasource that joins customer with delivery address:
The approach will still enable you to add filters per grid, and sorting and pagination will also work out of the box without writing a single microflow for the data retrieval:
You can use the view entity to generate informative labels, e.g., include the number of items in the next dropdown, or the number of items in the resulting datagrid: