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

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.

Reply
l6903b5
Frequent Visitor

Rolling values per category

I need help with DAX. 

 

I have this table:

business unityear_monthcategoryamountamount all categories12 month rolling sum 

12 month rolling sum 

all categories

12 month mov avg %
PS202206A41041040%
PS202207A69101953%
PS202208A610162955%
PS202209A34193358%
PS202210A918285155%
PS202211A37315853%
PS202212A00315853%
PS202301A512367051%
PS202302A1121479152%
I have filtered Year-month >= 202206 because column category is blank before this date. I have filtered on 1 business unit and 1 category, but there are more in de dataset. Amount all category = amount of all categories in business / year-month.
 

I have a date table. I need the Dax formula for the 12 month rolling sum. This is wat I have thus far:

12 month rolling sum =
var amount = COUNT('Table'[category])
Return  CALCULATE (amount, DATESINPERIOD (Calendar[DATE],LASTDATE ( Calendar[DATE] ),-365,DAY))
 
But it gives my the same as column amount. 
 
0 REPLIES 0

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

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

Top Solution Authors