Set criteria

Criteria are conditions that must be met in order to perform an action. Similar to the statement "if this happens…​", the criteria usually consist of a logical expression, an equality or inequality logical operator (e.g. =, ≠, >), and a logical state or constant value (e.g., TRUE, TODAY, Has no value or 42). For instance, the following criteria If A>=10 AND A⇐20 express the condition of having a record where the field "A" has a value between 10 and 20.

To add criteria

  1. Select the field on which you want to set the criteria to trigger the rule. Rules can be triggered on all field types, except for Link.

  2. Choose the Filter type, i.e. what kind of comparison you want to make on the selected field:

    1. The Absolute trigger condition verifies the value of the selected field for equality of inequality with an absolute value. The rule is triggered if the logical expression of the trigger condition evaluates to True.

    2. The Other field trigger condition compares the value of the selected field with the value of another field. The operator, choice of other field and additional settings depend on the type of the selected field.

    3. The Keyword trigger condition allows a choice among a number of keywords describing the status of the field value: Has no value, no value has been entered. CHANGED, the field value has been modified in some way, i.e., it has been inserted or updated, or deleted. INSERTED, a non-empty value is saved for the first time. UPDATED, an existing, non-empty value has been changed. DELETED, the field value has been removed (i.e., a new empty value is being stored). See a remark about keywords.

    4. The Record keyword trigger condition differs from the preceding one in that it is applied to the current record, rather than to one of its fields. As a consequence, the list of fields is not available once this condition is selected. The alternative values are: CREATED, a record has been created. UPDATED, one or more fields of a record being created or an existing record have inserted or changed value. DELETED, the current record is being deleted. And EXCLUSIVE UPDATE, one or more fields of an existing record have changed value.

      A rule triggered by a CREATED condition does not, in turn, trigger other rules based on the same condition. This is a feature designed to prevent circular loops.

      The UPDATED and EXCLUSIVE UPDATE criteria should be used with the utmost caution, because the broad scope of these types of trigger may lead to a very frequent execution of the rule, and therefore may significantly impact the system’s performance.

      The DELETED condition might be good to use for example to trigger an action on a related record (e.g., after a child record is deleted, recalculate the number of my existing child records and place the result on a field of the parent record) or to send a mail, but it cannot set a value on the triggered record that is about to be deleted, i.e., cannot set a value on itself upon deletion.

  3. Set the logical state or the constant value (depending on which Filter type you chose for the selected field).

  4. Optionally, keep the Only trigger once box checked in order to prevent rules from being triggered multiple times after a first time has occurred on the same record upon Save action. This is useful in case the rule turns out to be recursive. Note that this setting cannot be combined with Scheduled rules.

  5. Then click on the Add criteria button.

  6. Add more criteria if necessary (repeating the previous steps), since multiple conditions can be combined by using the operators AND and OR, which indicate logical-and and logical-or, respectively. The AND operator has the precedence over the OR operator, and is executed first. In the box that displays the trigger condition being assembled (in the lower portion of the form), this is expressed by lines beginning with an OR operator being indented.

It is important to note that the criteria will only be evaluated if there are changes in the fields included (or changes in the record in question, in case Record keyword is chosen). In other words, a rule will not be considered unless at least one of the items (field/record) in the criteria is used when creating or saving a record on application forms, or editing via imports.

This is, in order to perform the rule action, the criteria need to be evaluated first and return True (i.e., fulfill the required value or state).

To better understand this, see examples of criteria. See also complete examples of rules.

Once the criteria is set, click on the Next button to continue with the Set actions window.

To remove criteria

To remove a criterion, select it in the list and click the Remove button. If the first line is removed in this way, also the AND or OR operator that begins the following line is removed.

Criteria that is already added cannot be edited, unless they are first removed and then added again. New criteria can only be added at the bottom of the list.

To remove all the entered conditions, click the Remove all button.

Once the criteria is set, click on the Next button to continue with the Set actions window.

Examples of criteria - How they evaluate

Criteria will only be evaluated if at least one of the items (field/record) in the criteria is changed when creating or saving a record on application forms or imports. Evaluating to True will trigger the rule action.

Criteria in Change in application form/ Will criteria be evaluated? Will action be triggered Summary

MyNumber = 10

MyNumber is updated from 2 (original value) to 10, then the form is saved.

Yes (the field has changed value).

Yes (criterion returns True, i.e., fulfills the value needed to trigger the action).

Criterion is evaluated. Returns True. Action is triggered.

MyNumber = 10

MyNumber remains as 10. MyText is updated. The form is saved.

No (the field has not changed value).

-

Criterion is not evaluated, therefore the rule does not proceed.

MyNumber = 10 AND MyText = CHANGED

MyNumber remains as 10. MyText is updated. The form is saved.

Yes (one of the fields has changed).

Yes (both conditions return True, i.e., fulfills the value/state needed to trigger the action).

Criteria is evaluated. Returns True. Action is triggered.

MyNumber = 10 AND MyText = CHANGED

MyNumber is updated to 20. MyText is updated. The form is saved.

Yes (the fields have changed).

No (the AND operator used in criteria requires that both conditions return True, but only one of them did).

Criteria is evaluated. Returns False. Action is not triggered.

MyNumber = 10 OR MyText = CHANGED

MyNumber is updated to 30. MyText is updated. The form is saved.

Yes (the fields have changed).

Yes (the OR operator used in criteria requires that at least one of the conditions returns True, which is fulfilled).

Criteria is evaluated. Returns True. Action is triggered.

MyNumber = 30 AND Record = CHANGED

MyNumber remains as 30. MyNote is entered. The form is saved.

Yes (one of the items in the criteria has changed: the record, due to a modification made on one of its fields)

Yes (both conditions return True, i.e., fulfills the value/state needed to trigger the action).

Criteria is evaluated. Returns True. Action is triggered.

MyNumber = Has no value

A new record is imported. MyNumber field is empty.

No (the field has not changed, i.e., removed value when using this keyword).

-

Criterion is not evaluated, therefore the rule does not proceed.

MyNumber = Has no value AND Record = CREATED

A new record is imported. MyNumber field is empty.

Yes (one of the items in the criteria has changed: the record, through its creation).

Yes (both conditions return True, i.e., fulfills the value/state needed to trigger the action).

Criteria is evaluated. Returns True. Action is triggered.

Note that the comparison ≠ CHANGED, need to be configured together with another criterion that is changed in order to be evaluated. For instance, FieldA ≠ CHANGED AND FieldB = UPDATED.