Show TOC

Replacement from VariableLocate this document in the navigation structure

Characteristic value variables, hierarchy variables, text variables and formula variables with processing type Replacement Path can be replaced by the value from a different variable, the source variable. The value is determined either from the key, the external attribute of the key, the description, or the attribute value. You can also define an offset start and offset length. The variable is replaced in the Variables screen with each data release.

The target variable and source variable must meet the following prerequisites:

Table 1: Prerequisites for Replacement by Variable

Object

Properties

Target variable: The variable to be replaced should

  • not be input-enabled
  • Screen area Single Value

Source variable: The variable that is used to make the replacement

  • Not a hierarchy node variable
  • Input ready
  • Must exist in the query
  • Screen area Single Value or Interval
Variables Wizard

On the Variable - Replacement Rule dialog in the second step of the variables wizard, you specify that the variable derives its value from a variable. You then select the required variable by choosing Browse.

Variables Editor

In the variables editor under Replacement Rule, the system indicates that a variable serves as the source for replacing the variable. This replacement rule cannot be modified.

You can still change the object that you want to use for the replacement however. Choose Browse. A dialog box appears where you can select a different object.

The following properties are still modifiable:

  • Replacment With: Choose where the value of the variable will be determined from.
    • Key The value of the variable is replaced with the characteristic key.

    • External Characteristic (of the key) The value of the variable is replaced with an external value of the characteristic (external/internal conversion).

    • Name The value of the variable is replaced with the name of the characteristic.

    • [1ATTRREF] Characteristic Reference (Constant 1) (attribute value of the reference characteristic): The value of the variable is replaced with the value of an attribute of the characteristic that the source variable is defined on. This setting is only available for formula variables.

      Note

      If the attribute is time-dependent, the system cannot determine the variable value or does notreplace the variable with the expected value, since the key date of the query is not properly taken into account if it is variable.

      If the attribute and the target characteristic have the same basic characteristic, and this is compounded, the target variable must contain the uncompounded value. Proceed as follows:

      • The source characteristic is either the characteristic that the source variable belongs to or the attribute that the replacement will be made from. If the basic characteristic of the source characteristic and the basic characteristic of the target variable are the same, and the internal value is to be transferred, the system directly applies the uncompounded value.
      • In all other cases (if the basic characteristics are not the same, or replacement is to be made from the external format or the text), you must cut the uncompounded value with the offset and length specifications out of the target variable definition.
    • [0SIGNCH] Sign Change: The value of the variable is replaced with a value of a hierarchy attribute. You need this setting for sign reversal with hierarchy nodes. This is only available for formula variables.
  • After Aggregation (replacement of the variable after aggregation): This option is set by default. If you deselect this, the variable will be replaced before aggregation. It is not always possible to change this however. Replacement of the variable in the case of [1ATTRREF] Characteristic Reference (Constant 1) always takes place before aggregation. In the case of Name and [0SIGNCH] Sign Change, it takes place after aggregation.

  • Interpret Result As Boolean Value (True=1; False=0) As in the case of replacement from a characteristic value, this function is only available for formula variables. If you select this setting, the formula variable will not be replaced with a value (the key value for example) but merely specifies the existence of a value.

Under Details - as in the case of replacement from a characteristic value - you can define the values for using an interval (If Interval Use), as well as the Offset Start and Offset Length for the text output.