I have to create measure for calculating a rolling 12 months for Sales. I don't have date column but i have month colum(like 1,2,3 ..12) . How can i acheive it.
Solved! Go to Solution.
I have brought Year column and now i have concatenated Year and month column and created calculated column. Now i have the column like 201801.
How can i get the rolling 12 months.
You may have a look at below posts. Sample data and expected output will be helpful to provide an accurate solution.
If you have Year and month, you can use the function 'DATE'
You may try with below measure. Attached the sample file. If it is not your case, please share some sample data.
Measure = CALCULATE ( SUM ( Data[Sales] ), FILTER ( ALL ( 'Data' ), 'Data'[YearMonth] >= MAX ( Data[YearMonth] ) - 11 && 'Data'[YearMonth] <= MAX ( 'Data'[YearMonth] ) ) )
It’s time for another PBI Community recap!
Visit our Community Blog for articles, guides, and information created by fellow community members.
Need help with the Power BI Community? Our 'Using the Community' support articles are a great place to start.
Looking for inspiration on how to present your data? Need instructional videos? Check out our Galleries!