cant find formula for cumulative total of Period for the previous year with contract not running calender year.

RasmusKA

New Member
Joined
Apr 17, 2013
Messages
4
Hi Specialists

I have a report which have given me quite a headache. I can't fint out hov to make a cumulative total of Period for the previous year.

We have a contract that runs from april to march.So "april is month 1" and "march next year is month 12". I have made this in my date table.

I i for an example have chosen to see month 1 to 8, using slicers. So that would mean my table should show comsumption from april 2013 to november 2013. and for previous year it would be april 2012 to november 2012.

I have made the columns consumption "last year" "this year" "Total this year" "Total last year". Please se screendump below - sorry for the danish headers.

I cannot get the field "Total last year" to add up correctly.

The formula/measure fot Last year is "=CALCULATE(SUM(Sagsposter[Forbrug]);DATEADD(Dato[Dato];-1;year))

The measure for the Total Current year is (which works):
CALCULATE(
SUM(Sagsposter[Forbrug]);
filter(
allSELECTED(Dato);
Dato[Bu måned] <= MAX(Dato[Bu måned]))
)

Can anyone help me with findind the formula for the Total last year?

Example of what i tried:
=CALCULATE(
SUM(Sagsposter[Forbrug]);
filter(allSELECTED(Dato);DATEADD(Dato[Dato];-1;year));
filter(
allSELECTED(Dato);
Dato[Bu måned] <= MAX(Dato[Bu måned]))
)

I have tried parralleperiods. But i just cant get it to add up correctly.

I have tried for two days now and my hair is turning gray.

Any help appreciated.

Best regards
Rasmus
 
Last edited by a moderator:

Excel Facts

Copy PDF to Excel
Select data in PDF. Paste to Microsoft Word. Copy from Word and paste to Excel.

Forum statistics

Threads
1,223,983
Messages
6,175,777
Members
452,668
Latest member
mrider123

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top