Forum Discussion
Need help with Rolling Sum
- 5 years ago
Hi, Anonymous
Try to create a measure like this:
Rolling Average Numerator = VAR _sum12 = CALCULATE ( SUM ( 'PowerBI(Index)'[Total Return Numerator ("calculated reutrn" tab, Column K)] ), FILTER ( ALL ( 'PowerBI(Index)' ), EOMONTH ( 'PowerBI(Index)'[Return_id], 0 ) <= EOMONTH ( MAX ( [Return_id] ), 0 ) && EOMONTH ( 'PowerBI(Index)'[Return_id], 0 ) > EOMONTH ( MAX ( [Return_id] ), -12 ) ) ) RETURN IF ( HASONEVALUE ( 'PowerBI(Index)'[Return_id] ), _sum12, SUM ( 'PowerBI(Index)'[Total Return Numerator ("calculated reutrn" tab, Column K)] ) )my sample data:
Please refer to the attachment below for details
Hope this helps.
Best Regards,
Community Support Team _ Zeon Zheng
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi,
Sharing a photo will not help. You should create a measure to solve your question. Furthermore, there should be a Calendar Table as well. to get specific help, share the link from where i can download your PBI file.
Hi Anish,
Please see if you can access the PBI file through this link, still not able to figure out rolling annual sums yet. Please not I have removed alot of the sensitive data so it only shows the raw numbers. Would appreciate any help I could get.
- Ashish_Mathur5 years ago
Super User
That just takes me to a sign-in page.