Solved

moving 12 month total - power pivot DAX

Posted on 2016-09-13
1
41 Views
Last Modified: 2016-09-24
I am trying to produce a table that will give me my moving 12 month total.

sales start from 01/01/2013 and end in 01/08/2016 - there are no sales in my model before or after these dates.

I want my table only to display a value where it is possible to have a full 12 months worth of aggregated data. I therefore want to exclude the data highlighted in red below from the table.

Can anyone amend the measure below  to do this?

Note: Ideally I want the table to update automatically so that the range of dates included automatically extends as time goes on. For example, at the end of september 2016 another 12 month total will be included.

CALCULATE([total sales],DATESINPERIOD(BasicCalendarEnglish[DateKey],LASTDATE(BasicCalendarEnglish[DateKey]),-12,MONTH))
moving 12 month total
Thanks
Mike
0
Comment
Question by:mikes6058
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
1 Comment
 
LVL 40

Accepted Solution

by:
lcohan earned 500 total points
ID: 41796588
Please see details here as I believe they can help:

http://www.sqlbi.com/articles/rolling-12-months-average-in-dax/
0

Featured Post

Optimize your web performance

What's in the eBook?
- Full list of reasons for poor performance
- Ultimate measures to speed things up
- Primary web monitoring types
- KPIs you should be monitoring in order to increase your ROI

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Do you use a spreadsheet like Microsoft's Excel?  Have you ever wanted to link out to a non excel file on your computer or network drive?  This is the way I found to do it!
In this article we will learn how to fix  “Cannot install SQL Server 2014 Service Pack 2: Unable to install windows installer msi file” error ?
This Micro Tutorial will demonstrate how to create pivot charts out of a data set. I also added a drop-down menu which allows to choose from different categories in the data set and the chart will automatically update.
Finds all prime numbers in a range requested and places them in a public primes() array. I've demostrated a template size of 30 (2 * 3 * 5) but larger templates can be built such 210  (2 * 3 * 5 * 7) or 2310  (2 * 3 * 5 * 7 * 11). The larger templa…

623 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question