Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Image Removed  What if in certain situations, an attribute value is set by a default value as well as a business rule? What if both a business rule and a decision table exist for the same attribute? How is the sequence affected when the attribute default is a reference to a decision table? etc.

Image Removed

The inference engine first checks whether an attribute is user-set.
  - If so, all rules and defaults are ignored.

Image Removed

If not, the inference engine tries to find a rule amongst all decision tables, business rules, external rules and data rules that can set the attribute. Therefore the inference engine evaluates the condition of these rules.
  - If more than rule is found that can actually set the attribute, an error is displayed.
  - If exactly one rule is found that can set the attribute, that particular rule is fired.
  - If no rule is found that can set the attribute, the default value (default constant, default expression, default decision table or default external rule) is used to set the attribute.

Image RemovedIf no such default value (constant, expression, external rule or decision table) is found, the value remains unknown.
Image RemovedFurthermore, if any afore mentioned rule is part of a rule group, the participation of such rules is determined by the precondition of the rule group. In other words, if an attribute is not user-set and there is a decision table that could set it, but it is part of a rule group that has a precondition that is not met, the decision table does not participate.
Image RemovedIn case of inheritance, the inference engine will start searching for a way to derive the value of an attribute (a decision table, business rule, external rule or data rule) at the most specific level (the derived entity). If none exist there or their conditions are not satisfied, then the inference engine will look at the generic level (the base entity).

 

must be set to UNKNOWN in a decision table?

One could argue that to achieve this, the default should be set to unknown (a.k.a. no default is specified) and the situations in which the attribute should remain unknown should not be part of the decision table. This works fine, since a decision table and/or other logic elements will infer the value of that attribute and if no inference is applicable, the default value is chosen. Even if there is no default value, in that case the attribute remains unknown.

But what if you would want your decision table to be complete and hold all possible alternatives?
Or even in an incomplete decision table with a default, what if there are situations where the derived attribute really is unknown?

In that case, it must be possible to let the decision table set an attribute to unknown, using the symbol * or ? to achieve this.

See the example below:

Image Added

Image Added

The example above should be read as follows: For males, the discount for some fictitious product is 5%, 7% or 10%, depending on the age of the applicant. For females over 18 the percentage is 5%. For females aged 18 or younger the discount cannot be inferred, a case handler should determine the discount on a case-by-case basis. 

Panel
Section
Column
width50%

Main chapter: Design considerations

Previous: Local variables

 
Column