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

Table of Contents

Article

Building expressions with the Expression Builder

The Expression Builder guides you in constructing arithmetic and logical expressions in your application. You can open the Expression Builder in multiple locations across Designer Studio. For example, you can enter expressions in activities, data transforms, constraints, and most other places that compute a value at run time.

An expression is a single text element that, when evaluated, returns a single value. Use expressions to perform operations on data, including performing mathematical operations, comparing date and time values, manipulating text, transforming data, and converting data types.

The Expression Builder provides the following features and functionality:

  • An updated text editor
  • A navigation pane that displays functions in available libraries and properties within a selected page
  • The ability to drag functions and properties into the text editor
  • The ability to search for properties and noninternal functions
  • The ability to select properties and functions from prompts in the text editor
  • Automatic bracket matching
  • Syntax highlighting

Suggested approach

To build an expression, do the following steps.

  1. Build the expression by doing one of the following actions:
  • In the Expression Builder text editor, enter all or part of the expression.
  • Select properties and functions from a list by typing "." for a property and "@" for a function. Hover your mouse over a function to display a tooltip that describes what the function does.

Selecting properties and functions from a list

​Selecting properties and functions from a list

  • Use the navigation pane to drag functions and properties into the text editor. After you drop a function into the text editor, the arguments of the function are displayed. Provide values for the function.

Function arguments

Function arguments

You can reference properties from one of these areas in the navigation pane:

  • Current Page – Includes a list of properties from your current case context
  • Data Pages – Includes a list of properties available from application data pages
  • Parameter Pages – Includes properties defined as parameters on the invoking rule
  • Custom Pages – Includes properties from custom pages defined on the Pages & Classes tab of the invoking rule

Properties in the navigation pane

Properties in the navigation pane

  • Optional: Search for a property on your current page or for a non-internal function by entering all or part of the text to search for in the search field by clicking the Magnifying glass icon or by pressing Enter.
  1. Optional: Click Validate to check the syntax of the expression.​
  2. Click Submit.

 

Published April 14, 2015 — Updated December 28, 2016


78% found this useful

Related Content

Have a question? Get answers now.

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