Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Don't miss out! 2025 Microsoft Fabric Community Conference, March 31 - April 2, Las Vegas, Nevada. Use code MSCUST for a $150 discount. Prices go up February 11th. Register now.

Reply
01UmaManoharan
Frequent Visitor

Measure Slicer with repeated measures on various data points

Hi All,

 

I have a scenario where I have measures on below

cancelled in 15 days, cancelled in 30 days, cancelled in 45 days, cancelled in 60 days( 4 measures)

paid in 15 days, paid in  30 days , paid in 45 days, paid in 60 days(4 measures)

unpaid in 15, 30, 45, 60 (4 measures)

all the days performace are from issued date(eg: paid in 15 days from the issued date. cancelled date is also used for cancellations)

 

I need to create a measure slicer where i need this measure names as filter. when i pick 15 days in slicer it should slice my table for all paid, cancelled, unpaid with 15 days performace.

Can you guys help me on this please?

 

Note: I just simplified the scenario, would it be possible to create a measure slicer with filed parameters, when i have mulitple measures for one category.

i did not go for calculation groups as i have no idea how to pull the calculation groups in measure slicer. in table the output should be like measures in rows and measures in values. cancelled, paid and unpaid should be rows(these are DAX calculations not an actual value in column)

 

Thanks in advance

 

1 ACCEPTED SOLUTION
Sahir_Maharaj
Super User
Super User

Hello @01UmaManoharan,

 

Can you please try the following:

 

1. Create a Disconnected Table for the Slicer

TimeFrameSlicer = DATATABLE(
    "TimeFrame", STRING,
    "Days", INTEGER,
    {
        {"15 days", 15},
        {"30 days", 30},
        {"45 days", 45},
        {"60 days", 60}
    }
)

2. Create Dynamic Measures

DynamicMeasure = 
VAR SelectedTimeFrame = SELECTEDVALUE(TimeFrameSlicer[Days], 15)
RETURN
SWITCH(
    SelectedTimeFrame,
    15, [YourMeasureFor15Days],
    30, [YourMeasureFor30Days],
    45, [YourMeasureFor45Days],
    60, [YourMeasureFor60Days],
    BLANK()
)

Hope this helps!


Did I answer your question? Mark my post as a solution, this will help others!

If my response(s) assisted you in any way, don't forget to drop me a "Kudos" 🙂

Kind Regards,
Sahir Maharaj
Data Scientist | Data Engineer | Data Analyst | AI Engineer
P.S. Want me to build your Power BI solution? (Yes, its FREE!)
➤ Lets connect on LinkedIn: Join my network of 15K+ professionals
➤ Join my free newsletter: Data Driven: From 0 to 100
➤ Website: https://sahirmaharaj.com
➤ Email: sahir@sahirmaharaj.com
➤ Want me to build your Power BI solution? Lets chat about how I can assist!
➤ Join my Medium community of 30K readers! Sharing my knowledge about data science and artificial intelligence
➤ Explore my latest project (350K+ views): Wordlit.net
➤ 100+ FREE Power BI Themes: Download Now
LinkedIn Top Voice in Artificial Intelligence, Data Science and Machine Learning

View solution in original post

1 REPLY 1
Sahir_Maharaj
Super User
Super User

Hello @01UmaManoharan,

 

Can you please try the following:

 

1. Create a Disconnected Table for the Slicer

TimeFrameSlicer = DATATABLE(
    "TimeFrame", STRING,
    "Days", INTEGER,
    {
        {"15 days", 15},
        {"30 days", 30},
        {"45 days", 45},
        {"60 days", 60}
    }
)

2. Create Dynamic Measures

DynamicMeasure = 
VAR SelectedTimeFrame = SELECTEDVALUE(TimeFrameSlicer[Days], 15)
RETURN
SWITCH(
    SelectedTimeFrame,
    15, [YourMeasureFor15Days],
    30, [YourMeasureFor30Days],
    45, [YourMeasureFor45Days],
    60, [YourMeasureFor60Days],
    BLANK()
)

Hope this helps!


Did I answer your question? Mark my post as a solution, this will help others!

If my response(s) assisted you in any way, don't forget to drop me a "Kudos" 🙂

Kind Regards,
Sahir Maharaj
Data Scientist | Data Engineer | Data Analyst | AI Engineer
P.S. Want me to build your Power BI solution? (Yes, its FREE!)
➤ Lets connect on LinkedIn: Join my network of 15K+ professionals
➤ Join my free newsletter: Data Driven: From 0 to 100
➤ Website: https://sahirmaharaj.com
➤ Email: sahir@sahirmaharaj.com
➤ Want me to build your Power BI solution? Lets chat about how I can assist!
➤ Join my Medium community of 30K readers! Sharing my knowledge about data science and artificial intelligence
➤ Explore my latest project (350K+ views): Wordlit.net
➤ 100+ FREE Power BI Themes: Download Now
LinkedIn Top Voice in Artificial Intelligence, Data Science and Machine Learning

Helpful resources

Announcements
Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!

ArunFabCon

Microsoft Fabric Community Conference 2025

Arun Ulag shares exciting details about the Microsoft Fabric Conference 2025, which will be held in Las Vegas, NV.

December 2024

A Year in Review - December 2024

Find out what content was popular in the Fabric community during 2024.