Hi I have certain calculations on measures and a I have a measure called total points that is calculated in a rule .Now based on the value of this calculated Measure called total points I need to assign letter grades .
Say if total points is >75 then "B" etc..
Is it possible to set values like "A" , "B" via rule . I am getting error when i do this
[Grade]=if([Total Points] >75,'A','B'); but this syntax gives error .
Since strings cant be consolidated is this not possible in tm1 .
Thanks,
Assigning string value in a rule
-
- Posts: 128
- Joined: Tue May 23, 2017 12:45 pm
- OLAP Product: Tm1
- Version: 9.5
- Excel Version: 2010
-
- Posts: 128
- Joined: Tue May 23, 2017 12:45 pm
- OLAP Product: Tm1
- Version: 9.5
- Excel Version: 2010
Re: Assigning string value in a rule
Yeah that works now !! But when a zero supression is done all values for that string measure disappears to No Values .
I tried giving FEEDSTRINGS; at the top of the rule , but that doesnt fix the issue .
Any help to overcome this is appreciated .
Thanks,
I tried giving FEEDSTRINGS; at the top of the rule , but that doesnt fix the issue .
Any help to overcome this is appreciated .
Thanks,
-
- MVP
- Posts: 1815
- Joined: Mon Dec 05, 2011 11:51 am
- OLAP Product: Cognos TM1
- Version: PA2.0 and most of the old ones
- Excel Version: All of em
- Location: Manchester, United Kingdom
- Contact:
Re: Assigning string value in a rule
Did you put a feeder in as well or just feedstrings?
Declan Rodger
-
- Posts: 128
- Joined: Tue May 23, 2017 12:45 pm
- OLAP Product: Tm1
- Version: 9.5
- Excel Version: 2010
Re: Assigning string value in a rule
Yes feederstrings;
Skipcheck;
and feeders:
Skipcheck;
and feeders:
-
- Regular Participant
- Posts: 424
- Joined: Sat Mar 10, 2012 1:03 pm
- OLAP Product: IBM TM1, Planning Analytics, P
- Version: PAW 2.0.8
- Excel Version: 2019
Re: Assigning string value in a rule
Could you please post you whole rules including feeders statement. Thanks
"You Never Fail Until You Stop Trying......"
-
- Community Contributor
- Posts: 324
- Joined: Mon Jul 02, 2012 9:39 pm
- OLAP Product: TM1
- Version: PAL 2.0.8
- Excel Version: 2016
- Location: Sydney, Australia
Re: Assigning string value in a rule
Is this a c level string rule? If so, It willl show blank on zero supression, since there is no fed value in the consol.Analytics123 wrote:Hi I have certain calculations on measures and a I have a measure called total points that is calculated in a rule .Now based on the value of this calculated Measure called total points I need to assign letter grades .
Say if total points is >75 then "B" etc..
Is it possible to set values like "A" , "B" via rule . I am getting error when i do this
[Grade]=if([Total Points] >75,'A','B'); but this syntax gives error .
Since strings cant be consolidated is this not possible in tm1 .
Thanks,
You can make Grade a consol of Total Points, that way you dont need to feed.
-
- Posts: 128
- Joined: Tue May 23, 2017 12:45 pm
- OLAP Product: Tm1
- Version: 9.5
- Excel Version: 2010
Re: Assigning string value in a rule
FeedStrings;
SKIPCHECK;
['Letter Grade'] = S:if (['Total Points']<=DB('AR Parameter Scoring', 'Grade F', 'Upper Limit'),'F',if((['Total Points']>=DB('AR Parameter Scoring', 'Grade D', 'Lower Limit') & ['Total Points']<=DB('AR Parameter Scoring', 'Grade
D', 'Upper Limit')),'D',
if((['Total Points']>=DB('AR Parameter Scoring', 'Grade C', 'Lower Limit') & ['Total Points']<=DB('AR Parameter Scoring', 'Grade C', 'Upper Limit')),'C',if((['Total Points']>=DB('AR Parameter Scoring', 'Grade B', 'Lower Limit') & ['Total Points']<=DB('AR
ParameterScoring', 'Grade B', 'Upper Limit')),'B',if((['Total Points']>=DB('AR Parameter Scoring', 'Grade A', 'Lower Limit') & ['Total Points']<=DB('AR Parameter Scoring', 'Grade A', 'Upper Limit')),'A','INACTIVE')))));
FEEDERS;
['Total Points'] => ['Letter Grade'];
Hi , i have listed above my code used in rules , however total points measure is a calculation of few other fields in the model .
The issue I am having is on Zero suppression eventhought there are letter grades applicable , tm1 shows no values , I am not sure whats happening here .
Any help to trace back the issue is appreciated .Is the issue because when the totalpoints has a zero value , then the feeding doesnt happen for any cells .
Thanks,
SKIPCHECK;
['Letter Grade'] = S:if (['Total Points']<=DB('AR Parameter Scoring', 'Grade F', 'Upper Limit'),'F',if((['Total Points']>=DB('AR Parameter Scoring', 'Grade D', 'Lower Limit') & ['Total Points']<=DB('AR Parameter Scoring', 'Grade
D', 'Upper Limit')),'D',
if((['Total Points']>=DB('AR Parameter Scoring', 'Grade C', 'Lower Limit') & ['Total Points']<=DB('AR Parameter Scoring', 'Grade C', 'Upper Limit')),'C',if((['Total Points']>=DB('AR Parameter Scoring', 'Grade B', 'Lower Limit') & ['Total Points']<=DB('AR
ParameterScoring', 'Grade B', 'Upper Limit')),'B',if((['Total Points']>=DB('AR Parameter Scoring', 'Grade A', 'Lower Limit') & ['Total Points']<=DB('AR Parameter Scoring', 'Grade A', 'Upper Limit')),'A','INACTIVE')))));
FEEDERS;
['Total Points'] => ['Letter Grade'];
Hi , i have listed above my code used in rules , however total points measure is a calculation of few other fields in the model .
The issue I am having is on Zero suppression eventhought there are letter grades applicable , tm1 shows no values , I am not sure whats happening here .
Any help to trace back the issue is appreciated .Is the issue because when the totalpoints has a zero value , then the feeding doesnt happen for any cells .
Thanks,
-
- Community Contributor
- Posts: 324
- Joined: Mon Jul 02, 2012 9:39 pm
- OLAP Product: TM1
- Version: PAL 2.0.8
- Excel Version: 2016
- Location: Sydney, Australia
Re: Assigning string value in a rule
Feeder only fires when a numeric value goes from 0 to a value. Hence nothing when TotalPoints is zero. Also, are points calculations themselves? If so, there may be a feeding issue downstream.Analytics123 wrote:
Any help to trace back the issue is appreciated .Is the issue because when the totalpoints has a zero value , then the feeding doesnt happen for any cells .
Thanks,
P.s. I would invest a little time in making those rules bit more readable.