Rows

Each row in a decision table forms a rule.

Each numbered row in a table forms a rule. The values in the cells of the row contain the conditions and actions of the rule:

  Grade Loan Insurance
Min Max Rate Required
1 A 100,000 300,000 0,001 true

To make rows in a decision table easier to read, you can merge cells with conditions that are common to more than one rule. In the following table, the Grade A cells of rows 1 and 2 have been merged into one cell:

  Grade Loan
Min Max
1 A 100,000 300,000
2 300,000 600,000

You read the two rules as follows:

  • Rule 1

    if
       all of the following conditions are true:
          - Grade is A
          - the amount of Loan is between 100,000 and 300,000,
    then...
  • Rule 2

    if
       all of the following conditions are true:
          - Grade is A
          - the amount of Loan is between 300,000 and 600,000,
    then...

If a third row is added to the decision table, it can be shown in the following ways:

  • It can have a different value for the first condition:

      Grade Loan
    Min Max
    1 A 100,000 300,000
    2 300,000 600,000
    3 B 600,000 900,000
  • It can share the value for the first condition:

      Grade Loan
    Min Max
    1 A 100,000 300,000
    2 300,000 600,000
    3 600,000 900,000