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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
dobregon
Impactful Individual
Impactful Individual

Slicer MTD, QTD, YTD to filter dates using the slicer.

Hi all,

 

I have a question that i think it is not solved in the forum, as many of you i have the necessity to create some visuals/reports with the info in MTD, QTD and YTD. For that and now i'm doing new measures like CALCULATE(sum(sales),DATESYTD(date)) for every calculation and every MTD, QTD and YTD so, for every column i need to do 4 measures (simple actual without filter of dates, mtd, qtd and ytd) and it is not a big problem (only one time in every report) but i need to have one page for each MTD, QTD, YTD and i am asking if it is possible to create any type of slicer that i can filter for MTD, QTD, YTD...

 

This is an example of my source data:
Filter_sourcedata.PNG

 

And the table matrix that i want, something like that (this is an example in excel but the results in BI will be the same)Filter_result1.PNG

 

Now i'm creating one table matrix for each MTD, QTD and YTD with the calculated measures for each table, but i'm looking if it is possible to do something like that:Filter_result2.PNG

 

So, the MTD, QTD and YTD should be an slicer that when I click in MTD the report filters the dates of MTD and then the table shows the the values corresponding to that group of dates.

Could it be possible?

Thanks in advance and regards!



Did I answer your question? Mark my post as a solution! Appreciate with a Kudos!! (Click the Thumbs Up Button)
1 ACCEPTED SOLUTION
Anonymous
Not applicable

It may be easier if you create 20 measures like the one I wrote yesterday:

 

Final Value 1 = 
IF(HASONEFILTER(Table[CalcType]),
    SWITCH(SELECTEDVALUE(Table[CalcType]),
        "MTD", [Measure 1 MTD],
        "QTD", [Measure 1 QTD],
        "YTD", [Measure 1 YTD]
    ),
   BLANK()
)

You already have the MTD, QTD and YTD measures, and the 20 you need to create are just copy and paste. Not much work.

View solution in original post

21 REPLIES 21
dobregon
Impactful Individual
Impactful Individual

i dont know if you solve the issue after 5 motnhs... 



Did I answer your question? Mark my post as a solution! Appreciate with a Kudos!! (Click the Thumbs Up Button)

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.