Sales vs Budget YTD but skip Budget for Months that have not happened yet

mblondinde

New Member
Joined
Mar 16, 2014
Messages
1
Hello,

I'm pretty new to Powerpivot. I've had so much fun going through Rob Collie's book but now it's time to do real stuff and ... seems that I can't :(

It seems pretty simple to me but I can't get it to work. Here's my layout.

- 1 source for my products
- 1 source for my dates (1 entry per month)
- 1 source for my sales (granularity month)
- 1 source for my budget (granularity month)

Everything is related properly, I have Item# and Period in both my "fact" sources. I'm trying to create a YTD measure for my Sales and also Budget. But the thing is that now we're in March, I want my YTD Budget figure to only sum up until March, not all data for the year I have selected in my slicer. But by using the DATESYTD function, it adds up the complete year data.

I would like to setup a measure that automatically performs the YTD in the budget based on the latest period that exists in my Sales source. Am I asking too much?

Thanks for any help.

Regards,
Martin
 

Excel Facts

Round to nearest half hour?
Use =MROUND(A2,"0:30") to round to nearest half hour. Use =CEILING(A2,"0:30") to round to next half hour.
Create a dates table and year period table and try using the below

measure =CALCULATE([Total_Sales],DATESBETWEEN(Dates[Dates],DATEADD(LASTDATE(Year_Period[Next_Month_Start_Date]),MAX(Year_Period[Calendar_Period])*-1,MONTH),LASTDATE(Year_Period[Month_End_Date])))
 
Upvote 0

Forum statistics

Threads
1,223,990
Messages
6,175,817
Members
452,672
Latest member
missbanana

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