A date granularity problem...not sure if this is possible??

Russ Skinner

New Member
Joined
Jan 10, 2013
Messages
29
Not sure if the following is possible using PowerPivot either with a measure or calculated column, or whether I'll have to manually create a new table with the data - long hand.

Following is a simplified example of what I'm trying to achieve.

Following two tables linked to power pivot -

Energy, which contains energy billing data thus

8qyk.jpg


and a standard calendar table which runs from the start of 2011 to end of 2014.

bhje.jpg


The tables are linked by date fields.

For each line of billing data I've created a simple measure to calculate average energy use per day. So for first billing period = 700/79 = 8.86 units.

Now for the tricky part. I would like to be able to select a start and finish date or quarter (as defined in calendar table) and calculate the total units based on the billing period averages.

So for example from the 01/01/2012 to 31/12/2012 would use averages from the first 5 rows of the energy table summed over the applicable days of the bill periods between these two dates.

Similarly Quarter 1, 2012 would sum between the start and finish dates of this quarter defined in the calendar table.

Any ideas greatly appreciated.

Thanks

Russ
 

Excel Facts

Move date out one month or year
Use =EDATE(A2,1) for one month later. Use EDATE(A2,12) for one year later.

Forum statistics

Threads
1,223,959
Messages
6,175,644
Members
452,663
Latest member
MEMEH

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