Forum Discussion
Using Slicers to set thresholds
I want to be able to use a slicer with a numerical field to be used as a threshold when filtering other vizualisations, only taking values greater than, or less than the value in the slicer. Is this possible?
Hi angusmglfraser,
Based on my research, this requirement cannot be achieved by using aslicer. You need to use a parameter to do it.
Query Editer>Manage Parameter
Reference
https://powerbi.microsoft.com/en-us/blog/deep-dive-into-query-parameters-and-power-bi-templates/
Regards,
Charlie Liao
Hi angusmglfraser,
Currently, it have to be done from the "Edit queries" menu.
Regards,
Charlie Liao
4 Replies
- tringuyenminh92
Memorable Member
Hi angusmglfraser,
Yes, you can. For normal case (when user selects single filter options), i assume that you have fact table with 3 columns - 1 value column and 2 dims (MeasureA,category1,category2)
- Create new calculated table from value column:
filters = VALUES(Sheet1[MeasureA])
- Create new calculated measure for your fact table
Measure2 = CALCULATE(SUM(Sheet1[MeasureA]),FILTER(Sheet1,Sheet1[MeasureA] >= FIRSTNONBLANK('filters'[MeasureA],1) ))but what will be displayed/logic when user selects multiple options? in this case, you could try with max or min method instead of firstnonblank()
- v-caliao-msft
Microsoft Employee
Hi angusmglfraser,
Based on my research, this requirement cannot be achieved by using aslicer. You need to use a parameter to do it.
Query Editer>Manage Parameter
Reference
https://powerbi.microsoft.com/en-us/blog/deep-dive-into-query-parameters-and-power-bi-templates/
Regards,
Charlie Liao
- angusmglfraserNew Member
Can this parameter be set by some sort of interactive visual control on a page, or does it have to be done from the "Edit queries" menu?
- v-caliao-msft
Microsoft Employee
Hi angusmglfraser,
Currently, it have to be done from the "Edit queries" menu.
Regards,
Charlie Liao