Please enable JavaScript to view this site.

If a product has two options, A and B, that cannot be selected at the same time, these options are mutually exclusive. This is one of the most common rule scenarios to handle. Different strategies can be used to manage this depending on the situation.

Solution: Lookup parameter

A simple solution to handle mutually exclusive options without using rules is to model the two options as values within a single lookup parameter. Since a lookup parameter can only hold one value at a time, A and B cannot be selected simultaneously. However, this solution might not make sense if the two options are not logical alternatives to group under the same parameter.

Solution: Disallowed combination rule

If options A and B are defined using two different parameters (or multi-choice values), a simple solution is to create a disallowed combination rule that disables B if A is selected, and vice versa.

Solution: Two assignment rules

An alternative to disabling the other option is to clear the selection of B if A is selected, and vice versa. This can be achieved by using two assignment rules.

Let us say that A and B are modeled as two Boolean parameters. The two assignment rules should be configured as follows:

Assignment rule

Trigger parameters / value

Assignment parameters / values

1

A = Checked

B = Unchecked

2

B = Checked

A = Unchecked

 

This strategy can be applied regardless of whether A and B are modeled as Boolean parameters, multi-choice values, or lookup values of different lookup parameters. In the case of two lookup parameters, the assignment rules should clear out the value of the other parameter.

It might appear that these two rules would conflict with each other, since directly after a user action, both A and B could temporarily be selected. So, how does the rule engine know which rule to execute?

The answer is that the rule engine only runs rules that are relevant to the parameter that was last modified by the user. Therefore, if the user checks B, rule 2 will run; if the user checks A, rule 1 will run, which produces the desired result.

Note: For this behavior to work correctly, do not enable the Enforce assigned values setting on these rules. If the values are enforced, they will lock and prevent the user from switching between the options.

  

Keyboard Navigation

F7 for caret browsing
Hold ALT and press letter

This Info: ALT+q
Page Header: ALT+h
Topic Header: ALT+t
Topic Body: ALT+b
Contents: ALT+c
Search: ALT+s
Exit Menu/Up: ESC