Show TOC

Generic Primary AttributesLocate this document in the navigation structure

Use

The type of the generic primary attribute is used to automatically generate primary attribute values in the the configuration editor.

In the configuration context, each multiple context node should have precisely one attribute that is marked as primary. Sometimes, it is not possible to have this kind of attribute with the corresponding semantics. In such cases, you can use an attribute with the type primary so that the values of attributes are filled automatically.

A primary attribute is mainly for identifying the element, especially when combining configuration data, customizing data, and personalization data.

Data Type

The WDY_CONF_GEN_PRIMARY domain and a data element with the same name are available.

You can use the predefined data element, but if you need another label, you can generate your own data element on the basis of the named domain. The ABAP type is STRING.

Use

In the context editor of your configuration controller, you add an attribute to your multiple node, give it the type WDY_CONF_GEN_PRIMARY or another type based on the WDY_CONF_GEN_PRIMARY domain, and mark it as a primary attribute. You then proceed in the same way for all multiple nodes in this context if there is no 'natural' primary node.

When you start the configuration editor, each element of this node is automatically filled with data. If you want, these values can be overwritten.

Value Generation

The value is generated to meet the following requirements:

  1. It must be valid as a primary attribute. This means that it is unique in each context node.

  2. It must be possible to use it as a UI element identifier. For this purpose, the value only contains the characters A-Z, 0-9, and _. It is unique throughout the entire context.

  3. If possible, the value should not be used anywhere else at all. For this reason, the value starts with an underscore: _.

The algorithm for the name is as follow:

  1. It starts with _CFG_ for a configuration element and _CUS_ for a customizing element.

  2. This is followed by the name of the node.

  3. A unique number is than added, separated from the rest of the name using an underscore: _.

Handling of Existing Configurations

Generic Primary Attribute Handling in the Configuration Editor

Existing configurations are changed with the configuration editor.

If you call an existing configuration in change mode, the values are filled automatically. You just have to save the configuration to persist the data.

Report for Updating Existing Configurations

To update several configurations at once, use the WD_CFG_CHANGE_PRIMARY report.

  1. Execute the report.

  2. Enter the criteria to define configurations to be changed and then choose Execute (F8).

    The system displays a list of the configurations to be changed.

  3. Start the transformation.

    The old configuration data is stored locally on your computer as a backup.

To check that the report has run correctly, start the WD_ANALYZE_CONFIG_COMP application and display it there. If you run the report in the configuration editor, values for the primary attributes may be displayed even if they were not filled.