Skip to main content


         This documentation site is for previous versions. Visit our new documentation site for current releases.      
 

Calculating values with decision tables

Updated on May 11, 2022

To deliver an application that automatically at run time provides the most appropriate solutions, create logic with decision tables. Decision tables test a group of properties to match specified conditions and ultimately improve the flexibility of your application. By creating decision tables by using the low-code App Studio environment, you deliver software that can respond dynamically to varied conditions in business processes.

For example, you can create a decision table that calculates the account type for a customer based on a declared monthly income. The decision table returns a Standard account type for the income between 2,000 and 4,000 dollars, a Premium account type if the income is between 4,001 and 8,000 dollars, and a Gold account type for customers with income between 8,001 and 12,000 dollars.
Note: Only applications that are based on Cosmos React support decision tables in App Studio.
Before you begin:

    Navigate to the calculated field:

  1. In the navigation pane of App Studio, click Data.
  2. In the Data model section, click View.
  3. Open the calculated field:
    • To open a field form a case type data model, in the Case types section, click the case type that includes the field that you want to edit.
    • To open a field from a stand-alone data object, in the Data objects section, click the data object that includes the field that you want to edit.
  4. In the Fields list, click the Properties icon in the row of the calculated field that you want to edit.
  5. Associate the field with a decision table

  6. In the Configure field dialog box, expand the Advanced section, and then, in the Calculation section, select Use decision table.
  7. Define a decision table that you want to use:
    • To create a new decision table, in the list of options, select Custom decision table, click the Properties icon, and then define the table.

      For more information about creating decision tables for calculated fields, see Authoring decision tables in App Studio.

    • To reuse a decision table, in the list of options, select Existing decision table, and then, in the list of decision tables, select the table that you want to use.
  8. Close the field configuration dialog box by clicking Submit.

Have a question? Get answers now.

Visit the Support Center to ask questions, engage in discussions, share ideas, and help others.

Did you find this content helpful?

Want to help us improve this content?

We'd prefer it if you saw us at our best.

Pega.com is not optimized for Internet Explorer. For the optimal experience, please use:

Close Deprecation Notice
Contact us