IBM Integration Bus, Version 9.0.0.8 Operating Systems: AIX, HP-Itanium, Linux, Solaris, Windows, z/OS

See information about the latest product version

Configuring conditional mappings

You can create conditional mappings using the Graphical Data Mapping editor.

You can use the If, Else if, and Else transforms to control the flow of the mapping by setting conditions.

If, Else if, and Else operate as a group of conditional transforms. The condition is applied to the input element of the conditional transform. If the condition is satisfied, the nested transform within the conditional transform is run.

You can also conditionally run a single transform (such as a Move or Custom Transform) by entering the condition directly on the Condition tab of the transform.

Alternatively, you can use Custom Java™ or Custom ESQL to provide a condition function. See Custom Java or Custom ESQL for more information.

If you use a condition to optionally create one or more child output elements within a complex element, check that the condition is on the transform targeting the whole complex element, not just a child. If the conditional transform only targets a child, the folder element within the complex element will be created in the output before the condition is evaluated.

To map conditional transforms:

  1. For each conditional transform in the group, enter a condition in the Condition tab in the Properties view. The condition must be in the form of an XPath expression that returns either true or false, or a Java method call that takes standard Java type parameters and returns Boolean true or false.

    If you use a Java method and you have not already used a method from the Java class in a custom Java transform elsewhere in the map, you must create an import manually for the class. To import the Java class manually, you must configure the Java Imports tab on the Properties page of the map.

    1. You can change the order in which the statements in a condition are evaluated, by selecting a transform in the condition and then clicking the Move up or Move down arrows.
  2. Double-click the name of the conditional transform to create the mapping that operates for that condition.
    Note: The elements in the nested map must be mapped in order for the transform to run.
For more information about mapping transforms, see Transform types in the Graphical Data Mapping editor.

cm28666_.htm | Last updated Friday, 21 July 2017