Forum Discussion
mssqlsage
5 years agoRegular Visitor
Datesbetween behavior
Hi everyone, I'm attempting to return the sum of [Demand] as below, but limit it to only 7 weeks worth of values. I have a slicer on [TheDate], which is set to 10/18/2020. If I hard code i...
mssqlsage
5 years agoRegular Visitor
Hi amitchandak ,
Thank you for the solution. This is an approach I had not considered. I have added the appropriate columns to the date table, and using the following measure in an attempt to limit the results to the next 7 weeks after the slicer selection:
MyMeasureThatWorks =
CALCULATE(SUM('fact Allocation'[Demand]), FILTER(ALL('dim Date'),'dim Date'[Week Rank] >= max('dim Date'[Week Rank]) && 'dim Date'[Week Rank]<=max('dim Date'[Week Rank])+7))
I think I may still be off on the measure calculations, as not getting the 7-week limited data set expected.