Filter relevant values based on a calculated field

Hi Team,

How can I select relevant options for a filter based on a calculated field.
QS_FilterRelevantValues

Suppose I’ve created a calculated field basis the field which categorizes it into Letters and Numbers. How do I filter Field based on the chosen Calculated Field? I do not see the calculated field among the options to filter relevant values for the field.

Thanks,
Tanisha

Are you talking about the relevant values?

Or are you talking about parameters?

2 Likes

Hi Max,
Either options did not help. Maybe my example was not clear enough.
Re-wording and sharing my specific use case.

I have a calculated field, called Category that categorises groups of countries. This calculated field is built on top of Country
image

Formula for Category: ifelse(({Country Code} = ‘US’ OR {Country Code} = ‘UK’ ), ‘ONE’, ({Country Code} = ‘FR’ OR {Country Code} = ‘IT’ ),‘TWO’, ‘Others’)

Now, I have filters and controls enabled for both CountryCode and Category. What can I do to ensure only countries US/UK show up when i choose Category - ONE and FR/IT shows up when I choose Category TWO.

Hi @Tanisha_Shetty ,

Thanks for posting your query in the QuickSight community platform.
Coming to your problem I am facing the same issues when I am trying to use the calculated field as filter and use as relevant value but it has no options for the cascading filter.

**So for that you need to create any calculated field on the Dataset page area and use that field as filter in the analysis area. The you can show the show relevant options available for the filter.

Please find below the two picture where you can see the Calculated Field created in the Dataset area and Calculated Field created in the Analysis area.

image

So here if I want to add Show Relevant value on the basics of Test Data - Analysis Level Calculated Field or Employee Name it is not possible if you created the calculated field on the analysis area.


You can clearly see the Show relevant vale option is not available for the Test Data - Analysis Level Calculated Field. Only this option is available for the dimension filter.

So I created the same calculation on the Dataset level and its working fine.

image

If you see the Show Relevant option is not available previously on the analysis level calculated field but in the data set level calculated field the options is available.

So this is the way to add the filter relevant values based on a calculated field.

Thanks & Regards
Biswajit Dash

5 Likes

Hi Biswajit,

Thank you so much!
Creating the calculated field in the Dataset helped as Show relevant value option is not available for Calculated fields.

Thanks,
Tanisha

2 Likes

Hi @Tanisha_Shetty , Have you replicate it at your end? Is it working for you correctly or you are facing any challenges?

Thanks & Regards
Biswajit Dash

1 Like

Hi Biswajit,

I’ve replicated it and confirm it is working as required.

Thanks,
Tanisha

2 Likes

Hey! I have just encountered this same challenge, would it be possible to request having only relevant values for calculated fields used in controls in an analysis as well?

Sometimes because of the size of the Datasets we handle (SPICE) adding a calculated field there would result in the need for more space, correct?
It would be great to handle these cases directly in analysis!
Thank you all for the information here

Thanks for this update that it is working as required @Tanisha_Shetty! Very helpful to our peers on the Community. :slight_smile:

2 Likes

Hi @joana ,

You are highlighted good things but currently it is not possible in QuickSight. Whether your data set is in Direct Query mode or SPICE mode.

Thanks & Regards
Biswajit Dash

1 Like