Start of Content Area

Function documentation Assigning a Field  Locate the document in its SAP Library structure

Use

Using the structure overview and the data-flow editor you can map source fields of the source structure to one or more target fields.

Features

Target-Field Mappings with One Target Field

You can:

      Use drag and drop to select a source field in the structure overview and map it to a target field, or the other way around. The mapping editor displays this simple assignment in the data-flow editor.

      Drag a target field and one or more source fields from the structure overview to the data-flow editor. The data-flow editor automatically assigns the first source/target field pair. If a target field has already been mapped, then the mapping is displayed in the data-flow editor.

      Select a source and target field from the structure view by double-clicking. Note that you always transfer source fields to the data-flow editor by double-clicking. However, this is only possible for target fields if they have not already been assigned to a source field. When you double click a target field that has already been assigned, the system navigates to the corresponding mapping.

In the data-flow editor you can then connect source fields with standard functions or with your own functions (see: Functions in the Data-Flow Editor). In the simplest instance, assign a source field to a target field. The value of the source field is then transferred to the target field at runtime.

The following figure is an example of a target-field mapping with one target field:

This graphic is explained in the accompanying text

Most functions (like the function concat here) have a return value. By dividing the message mapping into multiple target-field mappings with one target field, you improve overall clarity.

Target-Field Mappings with Multiple Target Fields

In the case of functions with multiple return values (for example, JDBC Lookup in function category Conversions), is it not sufficient to only be available to transfer one target field to the data-flow editor. But in other cases, too, it may be necessary to use multiple target fields in the target-field mapping, for example, to improve the clarity of the semantics of the target-field mapping. The following figure provides an example:

This graphic is explained in the accompanying text

In this example, you could also model the calculation of firstName and familyName as two separate target-field mappings; however, the association would then be lost. Furthermore, if, as in this example, you use multiple target-fields in a target-field mapping, the mapping itself is quicker at runtime. Do not, however, be tempted to work with too many target fields within a single target-field mapping because it is easy to lose overall clarity.

To use multiple target fields in a target-field mapping, simply drag the required target fields to the data-flow editor by using drag and drop.

Displaying the Status

Icon Types

Icon

Meaning

This graphic is explained in the accompanying text

Attribute

This graphic is explained in the accompanying text

Element

This graphic is explained in the accompanying text

Element with maxOccurs = unbounded

This graphic is explained in the accompanying text

Variable

More information: Variables in the Target Structure

Icon Colors

Color

Meaning

White

Attribute or element not assigned

red

Attribute or element must be assigned to complete the mapping

yellow

Attribute or element has already been assigned but the corresponding mapping in the data-flow editor is not complete

green

Mapping to target field complete

Furthermore, collapsed target field names in the mapping editor are displayed in red if target field mappings for subnodes of the marked field name are still missing.

Note

The colors used for the data-flow objects in the data-flow editor have the same meanings as those used above.

 

 

 

 

 

End of Content Area