Using XPath Functions

You can use a variety of XPath functions in your data mappings to transform the data you transfer between applications.

To use an XPath function:
  1. Drag a source to a target to create a mapping.
  2. Click the target node to launch the Mapping Builder.
  3. Click Mapping Components.
    You can either find or browse for the function:
    • To find the function, type the full or partial name of the function in the Find field, and click the Find icon.
  4. Drag the function onto the mapping statement.
    If the function has a single parameter, it automatically inserts the existing mapping expression into the parameter.
    If the function has multiple parameters, it prompts you to select which parameter into which to insert the existing mapping expression.
  5. Select a parameter or None if you want to remove the existing mapping expression, and click OK.
  6. Click Save and Close.

Support for BPEL XPath Extension Functions

The mapper supports some BPEL XPath extension functions that you can include in your data mappings. The functions are available in both orchestrated integrations and basic map data integrations.

In the Source tree, expand the following categories under Functions. Place your cursor over a specific function to invoke a message that describes the syntax to use.

Under Functions... Available BPEL XPath Extension Functions

Expand Functions > Advanced

  • create-nodeset-from-delimited-string

  • decodeBase64

  • encodeBase64

  • generate-guid

  • lookup-xml

  • parseEscapedXML

  • parseXML

Expand Functions > Mathematical

  • max-value-among-nodeset

  • min-value-among-nodeset

  • square-root

Expand Functions > String

  • compare-ignore-case

  • create-delimited-string

  • format-string

  • get-content-as-string

  • get-localized-string

  • index-within-string

  • last-index-within-string

  • left-trim

  • right-trim

Using the length Parameter in the Substring Function in the Mapper

When you drag the substring function into the mapper, it may appear that you cannot add a value to the third parameter length. This is not the case. This is an optional parameter.

To add a value to the length parameter, perform the following steps:

  1. Drag and drop the substring function into the mapper. Only required parameters are automatically dropped.

  2. Right-click substring, and select Insert Child to add an empty row for the optional parameter.

  3. Once the third row is available, you can drag and drop or type into the field to complete the optional parameter.