Calculated measures usage and recommendations
In BOE XI3.x you can create calculated measures/key figures in universes.
Calculated Measures definitions are using MDX functions embedded in XML tags.
In order to create calculated measures, users must to create pure MDX expression embedded in XML tags: <EXPRESSION></EXPRESSION>In this new expression, we authorize to use any Designer function such as:
The check integrity ONLY validate the XML syntax and @Select function.No MDX parser is provided in this version of Universe Designer.
We recommend using @Select as much as possible rather than the measure definition for multiple reasons:
@SELECT is always resolved at query time
Life Cycle Management only ensure integrity with generated objects not with objects created by a user: @Select always guarantee the validity of the object
@Select function must be used like this: @Select(Parent class\Object)
This function is case sensitive as well as class name and object name.
@Select always refer universe metadata and not database definition.
A calculated measure can be used in a pre-defined filter.
The expression can be embedded in the filter definition ore referenced by using an @Select function.
In such a case the filter definition must start as following:
<FILTER EXPRESSION="@Select(Class\Object)"><FILTER EXPRESSION="IIF(.[Quantity] = 2000, 1, 0)">
SAP MDX restrictions:
The list below describes the main SAP MDX restrictions compared to Microsoft MDX functions:
Calculated measures must return numeric values only
Set functions such as SETTOSTR, TUPLETOSTR, MEMBERTOSTR, STRTOARRAY are not supported
Data type conversion functions such as CDate, CInt, CStr are not supported
Case When Else statement is not supported
Some operators such as <, >, <=, >= can not be used in any case
etc