Forum Discussion
Using a measure as a slicer
- 5 years ago
m_e_1203 , Looking at this seems like you need dynamic segmentation. Please refer if my video can help
https://www.youtube.com/watch?v=CuczXPj0N-k
File related to this video attached after signature
Hi,
Follow the Blog article here - https://www.daxpatterns.com/dynamic-segmentation/.
Hope this helps.
- m_e_12035 years ago
Helper II
Thank you for sharing the blog.
Unfortunately, I could not figure out how to complete this...
- Ashish_Mathur5 years ago
Super User
Hi,
Share the link from where i can download your PBI file.
- m_e_12035 years ago
Helper II
Ashish_Mathur Thank you for your reply. Since I cannot share the file due to confidentiality, I will explain here as much as I can.
What I would like to do is something like those below.
https://community.powerbi.com/t5/Desktop/Measure-as-Slicer-Workaround/m-p/613366#M292345
https://community.powerbi.com/t5/Desktop/Use-Measure-as-Slicer/m-p/1032054#M485879
-----------------------
(1)
Table (Qty Segment Table) created.
Qty Segment# : Segment
0: No purchase in 2020
1: Decrease
2: Same
3: Increase
-----------------------
(2)
This measure is in "Qty - Measure" folder.
Qty Segment# = IF(ISBLANK([Qty CY]), 0,IF([Qty Difference] < 0.000, 1,IF([Qty Difference] = 0.000, 2,3)))-----------------------(3)Create a measure like this in Qty Segment Table.
Category Selection = IF(SELECTEDVALUE('Qty Segment table'[Qty Segment#]) = 'Qty - Measure'[Qty Segment#], 1, 0)-----------------------(4)It did not filter.When I select both from the list it shows like this.0 value does not show 0......QtySegment# | Segment | QtySegment# | Qty Segment(Qty Segment Table) |----------------------------------------------------------------------------0 | No purchase | 3 | Increase1 | Decrease | 3 | Increase2 | Same | 3 | Increase3 | Increase | 3 | Increase-----------------------Thank you.