For each year I have the montlhy sales as per table below and I want to calculate the commulative total from Jan 2012 to Feb 2013.
2012 Sales COM. TOTAL
Jan 1 1
Feb 2 3
Mar 3 6
2013
Jan 1 7
Feb 2 9
Any ideas?
Thanks
Technology Tips and News
For each year I have the montlhy sales as per table below and I want to calculate the commulative total from Jan 2012 to Feb 2013.
2012 Sales COM. TOTAL
Jan 1 1
Feb 2 3
Mar 3 6
2013
Jan 1 7
Feb 2 9
Any ideas?
Thanks
You'll need a Calendar Table in your data model to achieve this!
This measure is called Running Total
=CALCULATE (
SUM ( TableName[Sales] ),
FILTER (
ALL (CalendarTable),
CalendarTable[FullDate] <= MAX (CaledarTable[FullDate])
)
)
If you need help with the Calendar Table - check out:
Microsoft Excel 2013: Building Data Models with PowerPivot (Alberto Ferrari and Marco Russo)
Chapter 12 - Performing Date Calculations in DAX