This rule takes value from previous month and puts into current month. This rule is written in 'Ilgalaikis turtas' cube.
['Month opening amount'] = N:DB('Ilgalaikis turtas',
AttrS('4 Time', !4 Time, 'prev_month'),!5 versions,'Month closing amount',!3 IT,!2_Tarnybos_Verslai);
What feeders should I write?
Feeders: how to feed cube on itself?
- Steve Vincent
- Site Admin
- Posts: 1054
- Joined: Mon May 12, 2008 8:33 am
- OLAP Product: TM1
- Version: 10.2.2 FP1
- Excel Version: 2010
- Location: UK
Re: Feeders: how to feed cube on itself?
'Month opening amount' relies upon 'Month closing amount', so i'd hazard a guess at something like;
['Month closing amount'] => ['Month opening amount'];
['Month closing amount'] => ['Month opening amount'];
If this were a dictatorship, it would be a heck of a lot easier, just so long as I'm the dictator.
Production: Planning Analytics 64 bit 2.0.5, Windows 2016 Server. Excel 2016, IE11 for t'internet
Production: Planning Analytics 64 bit 2.0.5, Windows 2016 Server. Excel 2016, IE11 for t'internet
-
- MVP
- Posts: 2836
- Joined: Tue Feb 16, 2010 2:39 pm
- OLAP Product: TM1, Palo
- Version: Beginning of time thru 10.2
- Excel Version: 2003-2007-2010-2013
- Location: Atlanta, GA
- Contact:
Re: Feeders: how to feed cube on itself?
Assuming you don't want to just use index numbers of the '4 Time' dimension add a new attribute called 'next_month' and then:kudzis wrote:What feeders should I write?
['Month closing amount'] => N:DB('Ilgalaikis turtas',AttrS('4 Time', !4 Time, 'next_month'),!5 versions,'Month opening amount',!3 IT,!2_Tarnybos_Verslai);
-
- Posts: 42
- Joined: Wed Nov 10, 2010 12:35 pm
- OLAP Product: Cognos 8 BI
- Version: 9.5.1
- Excel Version: Excel 2007
Re: Feeders: how to feed cube on itself?
Thank you tomok, it's working fine. I cannot use index numbers in this solution because it would include quarters, and I want to avoid it. Using 'next_month' attribute is very good solution.tomok wrote:Assuming you don't want to just use index numbers of the '4 Time' dimension add a new attribute called 'next_month' and then:kudzis wrote:What feeders should I write?
['Month closing amount'] => N:DB('Ilgalaikis turtas',AttrS('4 Time', !4 Time, 'next_month'),!5 versions,'Month opening amount',!3 IT,!2_Tarnybos_Verslai);
Steve V:
Your solution also works, but in very rare cases produces incorrect results.
-
- Posts: 42
- Joined: Wed Nov 10, 2010 12:35 pm
- OLAP Product: Cognos 8 BI
- Version: 9.5.1
- Excel Version: Excel 2007
Re: Feeders: how to feed cube on itself?
I have some other feeder questions:
1#:
My rule:
['Bendras nusidėvėjimas'] = N:['Nusidėvėjimas'] + ['Investicijų nudėvėjimas'];
FEEDER:
['Nusidėvėjimas', 'Investicijų nudėvėjimas'] => ['Bendras nusidėvėjimas'];
However, when I "Trace feeders" on 'NusidÄ—vÄ—jimas', my trace is empty. Why?
2#:
Rule:
['Įsigijimo vertė'] = N:IF (AttrS('4 Laikotarpiai', !4 Laikotarpiai, 'metai') @= '2011', ['2011 atidarymas'], continue);
FEEDER:
['2011 atidarymas'] => ['Įsigijimo vertė'];
Is this correct? Am I overfeeding here?
1#:
My rule:
['Bendras nusidėvėjimas'] = N:['Nusidėvėjimas'] + ['Investicijų nudėvėjimas'];
FEEDER:
['Nusidėvėjimas', 'Investicijų nudėvėjimas'] => ['Bendras nusidėvėjimas'];
However, when I "Trace feeders" on 'NusidÄ—vÄ—jimas', my trace is empty. Why?
2#:
Rule:
['Įsigijimo vertė'] = N:IF (AttrS('4 Laikotarpiai', !4 Laikotarpiai, 'metai') @= '2011', ['2011 atidarymas'], continue);
FEEDER:
['2011 atidarymas'] => ['Įsigijimo vertė'];
Is this correct? Am I overfeeding here?
-
- MVP
- Posts: 2836
- Joined: Tue Feb 16, 2010 2:39 pm
- OLAP Product: TM1, Palo
- Version: Beginning of time thru 10.2
- Excel Version: 2003-2007-2010-2013
- Location: Atlanta, GA
- Contact:
Re: Feeders: how to feed cube on itself?
According to this rule, 'Bendras...', Nusidev...', and 'Investici...' are all members of the same dimension, correct? If that's the case you can't do this:kudzis wrote:1#:
My rule:
['Bendras nusidėvėjimas'] = N:['Nusidėvėjimas'] + ['Investicijų nudėvėjimas'];
FEEDER:
['Nusidėvėjimas', 'Investicijų nudėvėjimas'] => ['Bendras nusidėvėjimas'];
['Nusidėvėjimas', 'Investicijų nudėvėjimas']
That syntax is saying those two elements are from two different dimensions. You would have to do:
['NusidÄ—vÄ—jimas'] => ['Bendras nusidÄ—vÄ—jimas'];
['Investicijų nudėvėjimas'] => ['Bendras nusidėvėjimas'];
The better answer is to make 'Bendras nusidÄ—vÄ—jimas' a consolidated node in the dimension and skip the rule. Then no feeder is needed.
-
- Posts: 42
- Joined: Wed Nov 10, 2010 12:35 pm
- OLAP Product: Cognos 8 BI
- Version: 9.5.1
- Excel Version: Excel 2007
Re: Feeders: how to feed cube on itself?
Thank you tomok. I've found out this also works:
[{'Investicijų nudėvėjimas','Nusidėvėjimas'}] => ['Bendras nusidėvėjimas'];
I've branched additional questions as a new topic.
[{'Investicijų nudėvėjimas','Nusidėvėjimas'}] => ['Bendras nusidėvėjimas'];
I've branched additional questions as a new topic.