ELLEV TM1 Function: Use and Syntax

The ELLEV function returns the numeric value of the level for an element in a dimension in TM1.

Syntax

The syntax is ELLEV(dimension, element); where:

  • dimension, is the dimension you are interrogating, and
  • element, is the element you want the level number for

Use of ELLEV

This function is used to determine the level of a specific element in a dimension.  It is often used in conjunction with an IF statement to then do something based on the result.

For example, if I want to test to see if an element is an N level element you would nest an ELLEV into an IF statement like the following. Then based on the outcome of the IF statement, I could populate a variable (in this case called sParent) for subsequent use in creating or updating a heirachy in a Turbo Integrator process.

IF ( ELLEV ('Products', vProduct) =0);
  sParent = ATTRS ('Products', vProduct, 'BossProduct');
  blah blah
ELSE;
  ITEMSKIP;
ENDIF;

This function is valid in both Rules and Turbo Integrator processes

If you like this post, please spread the love…

About John

Managing Director of Infocube. We are a management accounting consultancy that specialises in Business Analytics.

This entry was posted in Elements, Rule Functions, TI Functions, TI Processes and tagged ATTRS, ELLEV, ITEMSKIP. Bookmark the permalink.