The following examples show how the system performs a calculation if the FIX operator is in an exception aggregation or if an exception aggregation is in the FIX operator.
SUM ( SUM (X) by Product ) by Calendar MonthThe following values are calculated in the result:
Calendar Month | Product | Sales | Sales with Constant Selection by Product | 1‰ of Sales with Constant Selection by Product | Sales > 1‰ of Sales with Constant Selection by Product, Calendar Month |
---|---|---|---|---|---|
04.2004 | A | EUR 40 | EUR 100,000 | EUR 100 | 0 |
B | EUR 120 | EUR 100,000 | EUR 100 | 1 | |
Total | EUR 160 | EUR 100,000 | EUR 100 | 1 | |
05.2004 | A | 20 | EUR 100,000 | EUR 100 | 0 |
B | 320 | EUR 100,000 | EUR 100 | 1 | |
Total | 340 | EUR 100,000 | EUR 100 | 1 | |
Total | 500 | EUR 100,000 | EUR 100 | 2 |
SUM( FIX( SUM( Sales > FIX( 0.001 * (Sales with Constant Selection by Product, Calendar Month) ) by Product ) ) Calendar Month
Every FIX operator removes a reference characteristic: The outer one removes the GROUP-BY clause for Calendar Month, the inner one removes the GROUP-BY clause for Product. If there are multidimensional aggregations with nested formulas, the formula must be defined as in this example. Having two FIX operators ensures that both reference characteristics are removed. Note however that the outer FIX operator also removes the GROUP-BY clause for Calendar Month, which is also needed for the calculation of the sales figure in the inner formula. In cases like this, the only way to obtain the right result is to always calculate against the full reference key figure and with the basic key figure in its full granularity.