Filter which only shows relevant values

Hi All,

Wondering how I can create a filter which only shows relevant values.

Say I have a city field, and a country field. If I have a graph showing the populations of cities in USA, I want to allow users to filter what cities they are looking at, but I don’t want the filter to show them every possible city in the world, only the US ones (i.e., the ones on the graph).

I am creating a dropdown filter using the city field, but I cannot find any option to ‘show relevant values only’.

One workaround I have tried is creating a calculated field “US Cities”, an ifelse statement which returns the city field if the country = US, and null if not. I know the calculation works as when I drag the field into a table with all the cities it populates with cities for US cities only. But when I try to use this filter the only possible value is null…

Anyone have any ideas?

Found the answer to this!! business intelligence - AWS Quicksight - Update filter value based on another filter's input (category and sub-category) - Stack Overflow

You need to add both filters to the sheet, the filter you want to show, and the filter its values depend on (in my case City filter and Country filter). Then after adding both filters to the sheet, click the pencil icon in the corner of the City filter, and click ‘Control Options’, the last section. Click ‘Show relevant values’ and it will prompt you to choose the filter this filter depends on.