Forum Discussion
Same column, multiple filters
- 6 years ago
Hi PBIfanatic ,
We can create a measure to meet your requirement.
The measure calculate the sum total between [Slicer_value 1] and [Slicer_value 2].
Slicervalue total = var _selected1 = VALUES('Slicer 1'[Group]) var _selected2 = VALUES('Slicer 2'[Group]) var _value1 = CALCULATE(SUM('Table'[value]),FILTER('Table', 'Table'[Group] in _selected1)) var _value2 = CALCULATE(SUM('Table'[value]),FILTER('Table', 'Table'[Group] in _selected2)) return _value1 + _value2If it doesn’t meet your requirement, could you please show the exact expected result based on the table that we have shared?
BTW, pbix as attached.
Best regards,
Community Support Team _ zhenbw
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi PBIfanatic ,
We can create a measure to meet your requirement.
The measure calculate the sum total between [Slicer_value 1] and [Slicer_value 2].
Slicervalue total =
var _selected1 = VALUES('Slicer 1'[Group])
var _selected2 = VALUES('Slicer 2'[Group])
var _value1 = CALCULATE(SUM('Table'[value]),FILTER('Table', 'Table'[Group] in _selected1))
var _value2 = CALCULATE(SUM('Table'[value]),FILTER('Table', 'Table'[Group] in _selected2))
return
_value1 + _value2
If it doesn’t meet your requirement, could you please show the exact expected result based on the table that we have shared?
BTW, pbix as attached.
Best regards,
Community Support Team _ zhenbw
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
HI, I have tried this approach and it worked, But
When no values are selected , its actually shows double the actual output.
like return value1+value2. Could you please suggest someting for that.
For slicer 1 and 2 i am using number values.