
You can map:
- simple source elements to simple target elements
- source structures to target structures (where the source and target are
of the same type)
- multiple simple source elements to a simple target element
The following sections describe how to perform mapping for these particular
scenarios using the
Message Mapping editor.
Mapping
simple source elements to simple target elements
In the following
example, the source element called Name does not contain the same children
as the target element called Name:
Source |
Target |
Name
Title
First_name
Middle_name
Last_name
|
Name
Title
First_names
Last_name
|
To map one of the child elements, drag the element from the Source
pane onto the corresponding element in the Target pane; for example, drag
the Last_name source element onto the Last_name target element.
The
mapping is represented by a line between the source element and the target
element and an entry for the mapping in Xpath format appears in the Spreadsheet
pane. A triangular icon indicates which elements in the Source and Target
panes have been mapped.
Mapping source structures to target structures
In
the following example, the source element called Name has the same structure
as the target element called Name:
Source |
Target |
Name
Title
First_name
Middle_name
Last_name
|
Name
Title
First_name
Middle_name
Last_name
|
To map the entire source structure to the target structure, drag the
parent element (Name) from the Source pane onto the corresponding element
(Name) in the Target pane. All the child elements are mapped.
Mapping
multiple source elements to a simple target element
In the following
example, you want to concatenate the First_name and Middle_name source elements
to form a single target element called First_names:
Source |
Target |
Name
Title
First_name
Middle_name
Last_name
|
Name
Title
First_names
Last_name
|
To map multiple source elements to a simple target element, Ctrl+click
the appropriate source elements (First_name and Middle_name) and the target
element (First_names), then click . A concatenate function
appears in the Spreadsheet pane; you can
edit
this function to define how the concatenated target element looks,
for example, by adding a white space between the two source elements.

To customize the target element (for example, to
make the target value equal to the source value plus one), see Setting the value of a target element using an expression or function.
You cannot map a simple element if one of its ancestors also has a mapping.
For example, you cannot map Properties from source to target, then map Properties/MessageFormat.