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.
How to show data within over 30 Days and less than 30 days from a specific day?
Solved! Go to Solution.
@blockobito , in case you are not using date as a legend on donut visual
Rolling 30 day = CALCULATE(sum(Sales[Sales Amount]),DATESINPERIOD('Date'[Date],MAX('Date'[Date]),-30,Day))
Rolling 30 to 60 = CALCULATE(sum(Sales[Sales Amount]),DATESINPERIOD('Date'[Date],max(dateadd('Date'[Date],-30,day)),-30,day))
LTD(complete till date before 30 ) =
var _max = if(isfiltered('Date'),MAX( 'Date'[Date]) -30, today())
var _min = minx(all('Date'), 'Date'[Date]) // or minx(allselected('Date'), 'Date'[Date])
return
CALCULATE([net] ,DATESBETWEEN('Date'[Date],_min,_max))
Rolling Days Formula: https://youtu.be/cJVj5nhkKBw
In case you want to date as a legend, You need a slicer on an independent date table
//Date1 is independent Date table, Date is joined with Table
new measure =
var _max = maxx(allselected(Date1),Date1[Date])
var _min = _max -30
return
calculate( sum(Table[Value]), filter('Date', 'Date'[Date] >=_min && 'Date'[Date] <=_max))
Need of an Independent Date Table:https://www.youtube.com/watch?v=44fGGmg9fHI
Hi, @blockobito
If your problem has been solved, please accept the helpful reply as solution to close this thread, so that other community members will easily find the solution when they get the same issue.
Best Regards,
Community Support Team _ Eason
@blockobito , in case you are not using date as a legend on donut visual
Rolling 30 day = CALCULATE(sum(Sales[Sales Amount]),DATESINPERIOD('Date'[Date],MAX('Date'[Date]),-30,Day))
Rolling 30 to 60 = CALCULATE(sum(Sales[Sales Amount]),DATESINPERIOD('Date'[Date],max(dateadd('Date'[Date],-30,day)),-30,day))
LTD(complete till date before 30 ) =
var _max = if(isfiltered('Date'),MAX( 'Date'[Date]) -30, today())
var _min = minx(all('Date'), 'Date'[Date]) // or minx(allselected('Date'), 'Date'[Date])
return
CALCULATE([net] ,DATESBETWEEN('Date'[Date],_min,_max))
Rolling Days Formula: https://youtu.be/cJVj5nhkKBw
In case you want to date as a legend, You need a slicer on an independent date table
//Date1 is independent Date table, Date is joined with Table
new measure =
var _max = maxx(allselected(Date1),Date1[Date])
var _min = _max -30
return
calculate( sum(Table[Value]), filter('Date', 'Date'[Date] >=_min && 'Date'[Date] <=_max))
Need of an Independent Date Table:https://www.youtube.com/watch?v=44fGGmg9fHI
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
110 | |
98 | |
78 | |
64 | |
55 |
User | Count |
---|---|
143 | |
109 | |
89 | |
84 | |
66 |