Define the components of a business rule

Completed

Business rules encapsulate logic in a predefined set of steps. The steps run each time data is entered or modified and the data meets certain criteria to trigger the business rule.

Business rules are made up from the following components:

  • Conditions

  • Actions

The business rule editor is a visual drag and drop tool to create and update business rules.

Screenshot of a business rule editor.

Conditions

All business rules start with a condition. Conditions are shown in purple in the business rule editor. The first condition is a trigger and is used to determine if the business rule is run based on the values in the table's columns. A condition is always evaluated as either true or false. The true path is to the right of the condition, and the false path is beneath the condition. A condition is a simple if..then..else expression.

Within a condition, you can add multiple clauses with either AND or OR logic.

Screenshot of a business rule condition.

You can add further conditions to a business rule under the false path a condition to create more complex logic scenarios.

Actions

An action is a logic step that runs on either the true or false branch of a condition. Actions are shown in green in the business rule editor. You can chain multiple actions by adding a new action to the right-hand side of an action.

Action Description Applies to
Set Field Value Sets a value of a table column. You can set the value to a hard-coded value, to the value of another column, or with a simple formula. You can also clear the value of the field. All scopes
Set Default Value Sets the value of a column but only when the column has no value (null). All scopes
Show Error Message Prevents the save of the row. In model-driven app form, the error message is displayed within the form, for server-side the error message is passed back to the calling process. All scopes
Lock/Unlock Lock changes the column's property to read-only. Unlock enables the user to change the value of the column. Model-driven app
Set Visibility Setting to No hides the column on the form. Setting to Yes displays the column on the form Model-driven app
Set Business Required Sets the requirement level of the column on the form to Business Required or Not Business Required (Optional). Setting the column to Business Required shows a red asterisk next to the column's label and prevents the rows from being saved if the column's value is empty. Model-driven app
Recommendation Shows a light bulb icon next to the column's label. When the icon is selected, the user is prompted and accepting the prompt the rule can set field values. Model-driven app

Screenshot of business rule actions.