Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!To celebrate FabCon Vienna, we are offering 50% off select exams. Ends October 3rd. Request your discount now.
Hey guys, so I'm calculating the current trailing 12 month totals (May 2021 through May 2022 sales), and I'm trying to compare this to the prior trailing 12 month totals (May 2020 through May 2021 sales). I can get the current trailing 12 month total by using the DAX formula below, but how to do I get the prior trailing 12 month total? Any suggestions would be great. Thanks!!
Solved! Go to Solution.
@iluvcoding_91 , Rolling 12 before 12
Rolling 12 = CALCULATE(sum(Sales[Sales Amount]),DATESINPERIOD('Date'[Date ],eomonth(MAX('Date'[Date ]),-12) ,-12,MONTH))
Hi @iluvcoding_91,
May I know whether you get the desired result with the dax from amitchandak? If there is any post helps, then please consider Accept it as the solution to help the other members find it more quickly. If you still have problems on it, please feel free to let me know. Thanks a lot!
Best Regards,
Community Support Team _ Caiyun
@iluvcoding_91 , Rolling 12 before 12
Rolling 12 = CALCULATE(sum(Sales[Sales Amount]),DATESINPERIOD('Date'[Date ],eomonth(MAX('Date'[Date ]),-12) ,-12,MONTH))