- LEFT('Example', 3) returning 'Exa',
RIGHT('Example' 3) returning 'ple',
MID('Example', 2, 4) returning 'xamp'.
LEFT, RIGHT, MID Functions in Rules/TI
-
- MVP
- Posts: 195
- Joined: Wed Jul 22, 2009 10:35 pm
- OLAP Product: TM1
- Version: 9.5.2 FP3
- Excel Version: 2010
LEFT, RIGHT, MID Functions in Rules/TI
Common functions like LEFT, RIGHT and MID functions both in Rules and TI would make coding much easier to write and read.
- Steve Rowe
- Site Admin
- Posts: 2416
- Joined: Wed May 14, 2008 4:25 pm
- OLAP Product: TM1
- Version: TM1 v6,v7,v8,v9,v10,v11+PAW
- Excel Version: Nearly all of them
Re: LEFT, RIGHT, MID Functions in Rules/TI
Just checking that you know about subst and delet?
Can't see them implementing functions that already exist but with a different name. It would be nice if TM1 and Excel function names were more closely aligned but I don't see it as too much of a drama. Function names are not even aligned within TM1 (Excel has DBRW, Rules DB and TI CellGetN).....
Can't see them implementing functions that already exist but with a different name. It would be nice if TM1 and Excel function names were more closely aligned but I don't see it as too much of a drama. Function names are not even aligned within TM1 (Excel has DBRW, Rules DB and TI CellGetN).....
Technical Director
www.infocat.co.uk
www.infocat.co.uk
-
- MVP
- Posts: 195
- Joined: Wed Jul 22, 2009 10:35 pm
- OLAP Product: TM1
- Version: 9.5.2 FP3
- Excel Version: 2010
Re: LEFT, RIGHT, MID Functions in Rules/TI
I must agree i went to far with MID example (which actually is the same as SUBST). Also the LEFT is easily replaceble with SUBST (just a small difference in syntax).
But the RIGHT function is not that "user friendly" to achieve.
IMHO it is much easier both to WRITE and READ:
"RIGHT(sVariable, 3)"
instead of
"SUBST(sVariable, LONG(sVariable)-2, 3)"
or
"DELET(sVariable, 1, LONG(sVariable)-3)"
But yes, it is not "too much of a drama".
But the RIGHT function is not that "user friendly" to achieve.
IMHO it is much easier both to WRITE and READ:
"RIGHT(sVariable, 3)"
instead of
"SUBST(sVariable, LONG(sVariable)-2, 3)"
or
"DELET(sVariable, 1, LONG(sVariable)-3)"
But yes, it is not "too much of a drama".