What's the right way to feed children?
Posted: Thu Mar 14, 2013 5:48 pm
Apologies for the subject line being so open to witty replies but.....
I've got budget data at a monthly level and I want the cube to calculate daily budget values.
I've populated a 'daysinmonth' attribute for every day so I can write a rule that does the calculation.
As a rookie Tm1 developer though, I don't know how best to feed the cells.
A more concrete example is...
Dimension time has
Date attribute(Daysinmonth) attribute(Period)
1-1-2013 31 2013-Jan
2-1-2013 31 2013-Jan
3-1-2013 31 2013-Jan
..
..
..
2013-Jan n/a n/a
2013-Feb n/a n/a
So in my Time dimension I have a mix of dates and 'periods'.
I've got a measure 'BudgetByPeriod' which I've loaded with the monthly values . eg 2013-Jan has a value of 123456
and a rule that looks like
['Budget']=n:(DB('data',!Dim1,!Dim2,ATTRS('Time',!Time,'Period'),'BudgetByPeriod'))/ATTRN('Time',!Time,'DaysInMonth');
Which to me means, for the daily budget figure, lookup the budget for the month and divide it by the number of days in the month.
so Budget should be 123456/31
The problem is, I don't know how to write a feeder that forces a budget calculation at daily level.
The best(terrible) solution I've managed to devise is to have a 'isfed' measure, which I set to 1 for every possible value via TI process.
(Alternatively, I could calculate the budget values daily and load them (or possibly use a TI script to calculate them)).
As always your help is appreciated!
P
I've got budget data at a monthly level and I want the cube to calculate daily budget values.
I've populated a 'daysinmonth' attribute for every day so I can write a rule that does the calculation.
As a rookie Tm1 developer though, I don't know how best to feed the cells.
A more concrete example is...
Dimension time has
Date attribute(Daysinmonth) attribute(Period)
1-1-2013 31 2013-Jan
2-1-2013 31 2013-Jan
3-1-2013 31 2013-Jan
..
..
..
2013-Jan n/a n/a
2013-Feb n/a n/a
So in my Time dimension I have a mix of dates and 'periods'.
I've got a measure 'BudgetByPeriod' which I've loaded with the monthly values . eg 2013-Jan has a value of 123456
and a rule that looks like
['Budget']=n:(DB('data',!Dim1,!Dim2,ATTRS('Time',!Time,'Period'),'BudgetByPeriod'))/ATTRN('Time',!Time,'DaysInMonth');
Which to me means, for the daily budget figure, lookup the budget for the month and divide it by the number of days in the month.
so Budget should be 123456/31
The problem is, I don't know how to write a feeder that forces a budget calculation at daily level.
The best(terrible) solution I've managed to devise is to have a 'isfed' measure, which I set to 1 for every possible value via TI process.
(Alternatively, I could calculate the budget values daily and load them (or possibly use a TI script to calculate them)).
As always your help is appreciated!
P