This content has been archived and is no longer being maintained.

Table of Contents

Article

Expression Builder enhancements for certain rule types

Several enhancements have been made to the Expression Builder so that you can efficiently build expressions in a user-friendly environment.

These enhancements apply to the Expression Builder for the following types of rules:

  • Data Transform
  • When
  • Map Value
  • Decision Tree
  • Decision Table
  • Strategy

Expression Builder commenting and line numbersExpression Builder commenting and line numbers

The Expression Builder provides real-time validation of expressions as you enter them. You can receive immediate feedback on your syntax as you compose your expressions.

For example, error icons are displayed next to the lines that contain syntax errors. Hover your mouse over the error to view additional information.

Expression Builder syntax errorExpression Builder syntax error

You can also receive immediate feedback on your expression by clicking Test to open the Test data pane. Errors are displayed in the area above the text editor. For example, the Reviewer property in the following figure is a Text type, and you cannot perform an arithmetic function on it.

Expression Builder expression validation errorExpression Builder expression validation error

The Test data pane displays all the scalar properties that are used in the expression in the order in which they appear. Default values for properties depend on the type of property type. In the following figure, the properties are decimal types, and so the default values provided are 0 (zero).

Expression Builder Test paneExpression Builder Test data pane

To test the entire expression, enter values for all the properties, and click an area of the Expression Builder other than the input fields. The result is displayed in the Result field above the text editor.

Testing the entire expression in the Expression BuilderTesting the entire expression in the Expression Builder

To test a portion of the expression, enter values for the properties that you want to test and highlight the portion of the expression to test. The result is displayed in the Result of selection field above the text editor.

Testing a portion of the expression in the Expression Builder

Testing a portion of an expression in the Expression Builder

Published June 23, 2016 — Updated July 13, 2016


100% found this useful

Have a question? Get answers now.

Visit the Pega Support Community to ask questions, engage in discussions, and help others.