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

Earn a 50% discount on the DP-600 certification exam by completing the Fabric 30 Days to Learn It challenge.

Reply
HKInd
Helper I
Helper I

Need Help with Last 3 Weeks Total Calculation in Report Slicer

Hi All,

Please help..!

 

Need help with calculating "last3WeeksTotal" based on the selected Weekending date in the slicer. The formula I provided is showing blank results:

 

I have applied below DAX but it showing blank result :- 

3Wkstotal =
CALCULATE(
    SUM('Date_set'[Revenue]),
    FILTER('Date_set',
    'Date_set'[Order Stage] = "Ordered"
    &&'Date_set'[Scope] = "Order"
    ),FILTER('CalendarDate','CalendarDate'[Date]>=[Selected_date]-27 && 'CalendarDate'[Date]<=[Selected_date]-7))

 

Report link below:

https://www.dropbox.com/s/6jvwyryae34ormg/3Weeks%20Total%20issue.pbix?dl=0 

HKInd_0-1690136549051.png

Any suggestions or corrections are welcome!

3 REPLIES 3
aj1973
Community Champion
Community Champion

hI @HKInd 

here 3 weeks of 21 days

aj1973_0-1690151006105.png

20 days

aj1973_1-1690151144568.png

22 days

aj1973_2-1690151185470.png

 

Regards
Amine Jerbi

If I answered your question, please mark this thread as accepted
and you can follow me on
My Website, LinkedIn and Facebook

Please see below screenshot of what help i need, I have two columns Dates and Sale and at the bottom i have written start date of the week and end date of the week and total is 1675 from 3July to 23July when 30July Weekending date is selected. 

HKIndia_0-1690177945976.png

 

@aj1973  Thanks for your reply, But It should work on slicer basis, If i selected date in slicer it should change date calculation accordigly. You have removed selectedvalue feature in solution.

Helpful resources

Announcements
LearnSurvey

Fabric certifications survey

Certification feedback opportunity for the community.

April Fabric Community Update

Fabric Community Update - April 2024

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