Expression Builder

You use the Expression Builder feature to create complex or intricate expressions that are lengthy and time consuming to enter. Expression Builder provides a large text editing area and access to a library of predefined functions and operators that facilitate creation of complex transformation expressions.

You cannot use the Expression Builder feature for a property that is a foreign key (FK), reference property (Ref), or generated value (GV).

When you select a property on the Target pane of the Mapping window and then click Expression Builder, Integration Composer displays the Expression Builder dialog box.

The top half of the dialog box is an Expression pane that displays the expression you create. The lower half of the window has two panes:

To resize the panes, position the cursor over the bar that separates the panes until the cursor changes to a Horizontal Resize Cursor (↔). Click the mouse device and drag it to increase or decrease the size of a pane.

Operators

The Operators pane in the lower left corner of the dialog box provides a selection of operators that you can use to build the expression.

Categories

You can expand the Categories tree in the lower pane to view classes and properties from the data source, as well as the predefined functions available in Integration Composer.

  • Data Source: You can expand Data Source in the Categories tree to display the properties available for the class that you selected in the Source pane on the Mapping window. You can double-click a property to select it for the expression.

    Integration Composer displays only properties for the source class that you selected in the Mapping window when you clicked the Expression Builder icon.

  • Functions: You can expand Functions in the Categories tree to list the predefined functions that you can use to build the expression. The functions are organized into the following subcategories: text, SQL, math, mapping execution flow, mapping, logical, and date/time.

    When you expand the tree, you can double-click an item to select it for the expression. Integration Composer displays the selected item in the Expression pane of the dialog box.

When creating expressions using the Expression Builder dialog box, do not use the tab key. You can use the space bar to add additional spaces when necessary.

Defining function parameters

Expression Builder provides a feature that lets you define a value or range of values for functions. When you select a specific function, a Function Definition icon appears next to the highlighted function.

When you click this icon, Integration Composer displays the Function Parameters dialog box, which lets you select additional parameters related to the function. It also contains Help text that describes the selected function.

You can further define the function by selecting one of the parameters. When you select a parameter, Integration Composer displays a Function Parameters icon for the selected function. Clicking this button opens a second Expression Builder dialog box that lets you create an expression for the selected parameter.

Syntax errors

Syntax errors occur if words or symbols are in the wrong order or if you omit them when you create an expression using the Expression Builder. To display syntax errors, click OK on the Expression Builder dialog box. Integration Composer displays the reason for the error in the Errors section at the bottom of the dialog box.

When you position the cursor over the error message, Integration Composer displays a ToolTip with information about the error.

Integration Composer does not let you click OK and exit without correcting the syntax error. You must correct the error before you can use the expression in the mapping.



Feedback