Show TOC

Procedure documentationAdding a Condition Locate this document in the navigation structure

 

You add conditions to a rule when you want the associated actions in the rule to be performed only when the conditions are satisfied.

Example Example

Consider the rule:

If

Student aggregate score greater than or equal to 60

Then

Display message equals “This student qualifies.”

In this rule the condition is that the aggregate score must be 60% and above. Only if this condition is fulfilled is the student considered qualified.

End of the example.

Conditions are always of the format: “LHS value comparator RHS value”. In the rule editor, under the If section of a rule you can specify the LHS value and RHS value and choose an appropriate comparator.

Procedure

  1. Locate the ruleset (Where is my ruleset?) and double-click the ruleset node.

  2. In the Outline view, choose the rule node.

  3. In the rule editor that appears, under the If section, choose the Add icon.

    The default rule condition: Operation.isSuccessful() Equals true appears.

  4. To edit the default rule condition:

    1. Choose the LHS value:Operation.isSuccessful() and in the drop down menu choose a definition or an alias. You can also choose <Add a new expression> to add compound expressions.

      More Information: Creating and Editing Compound Expressions

    2. Choose the comparator:Equals and choose a comparator in the drop down menu.

      More Information: List of Return Types and Comparator Choices for Conditions

    3. Choose the RHS value after the comparator and in the drop down menu choose a definition or an alias. You can also choose <Add a new expression> to add compound expressions.

      More Information: Creating and Editing Compound Expressions

      Note Note

      To enter static values, choose each component in the default rule condition (Operation.isSuccessful() Equals true) and enter the value in the inline text box.

      End of the note.