Entering content frameFunction documentation Message Mappings Locate the document in its SAP Library structure

Use

A message mapping refers to a mapping of messages and is supported by a graphical mapping editor. The editor enables you to design a structure mapping between any two XML structures and the connection to a value mapping.

The mapping tool generates Java source code from the graphical mapping description that is then compiled and packed in a Jar file that the Integration Engine executes at runtime.

Features

The mapping editor can import any schema ((fault) message types, imported RFCs, or IDocs) from the Integration Repository, as well as XML schema definitions (XSD) and any XML file. In the case of XSD files (the repository schemas also use this format), the mapping editor generates an XML representation for both the source structure and the target structure.

Main Functions Area of the Mapping Editor

Once you have created a message mapping the system navigates to the mapping editor Design tab page. In the screenshot below, the request schema of an RFC module and a message type have been loaded and a simple mapping defined (the tab page was removed from the Integration Builder beforehand):

This graphic is explained in the accompanying text

You have the following options when defining a message mapping:

Therefore, a message mapping comprises various target field mappings. Once you have defined a mapping for each mandatory target field your message mapping is complete. To test your message mapping, navigate to the Test tab page (see: Testing Message Mappings).

Functions of the Object Toolbar

Function

Use

This graphic is explained in the accompanying text Compile

Provided that the message mapping is complete, you can use this function to compile the Java source files generated for the mapping.

This graphic is explained in the accompanying text Update

If you called a repository schema in the mapping editor that has since been changed in the Integration Repository, the changes will not be visible in the mapping editor. To apply changes of this type to the source and target structures, choose Update.

This graphic is explained in the accompanying text Delete Mapping

Deletes all target field mappings.

This graphic is explained in the accompanying text Text Preview

Displays all target field mappings including the functions used as text (the data-flow editor is hidden from view). Lines in red indicate missing target field mappings. The Quickinfo for a green target field displays the corresponding mapping.

This graphic is explained in the accompanying text Map Selected Fields and Substructures if Names Are Identical

Before you execute this function, first select a node in both the source and target structure that belong to each other. You can then automatically assign subnodes that have identical names (names are case sensitive here). This function is particularly useful for simple mappings, for example from RFC XML to Proxy XML.

Functions of the Context Menu

To define target mappings for different positions of a target element that occurs frequently, the context menu for the target structure has the function Duplicate Subtree (see: Duplicating Subtrees). You have the option of deleting any duplicates that you create.

Activities

To define a mapping between two XML structures, proceed as follows:

  1. Create a message mapping in the design maintenance of the Integration Builder (also see: Creating a New Object).
  2. Using the structure overview and the data-flow editor, assign one or more source fields to a target field. This type of mapping is also called a Target Field Mapping. It is possible to assign one source field to multiple target fields (see: Assigning a Field).
  3. If necessary, enhance the target field mapping in the data-flow editor. To do so, connect the source fields to the target fields by using the standard functions of the mapping editor. You can also create user-defined functions in Java in the mapping editor and then also use them in the data-flow editor (see also: Data-Flow Editor).
  4. Carry out the last two steps for at least all mandatory target fields.

Result

The mapping is complete and ready for testing when all the fields in the target structure have either green or white icons. A yellow icon indicates that a target field mapping is incomplete, while a red icon indicates that a target field is unassigned.

 

 

 

 

Leaving content frame