Constraint rule conditions should be met in order to trigger a rule. There may be more than one condition for a rule. A constraint rule condition is met when the Sale rep adds a product that is part of the product scope you defined in constraint rule condition, to the cart. When the constraint rule condition is satisfied, the constraint rule action is executed on the cart. Different conditions are associated with an expression. When the condition association expression is not specified, all the conditions should be met in order to trigger the rule.

The rule condition is defined by product scope. Product scopes are groups in which the product belongs or a set of fields you can use as conditions. The product scope could be specific to a Product, Product Family, Product Group, Product Option Group, and a Product Field Set.  Product scops are explained in detail later in this section.

You can define additional condition criteria like Country Codes or Color.  The additional criteria on the condition is based on the line item object. Condition Criteria filter conditions that are applied to the line item created from the selected products that are within the product scope definition.

When criteria is defined, the condition is met when the product scope specification and criteria are both met. For example, based on your company's requirement, you cannot sell Product B if you are selling more than 3 units of Product A. In this case, you can define condition criteria to validate the quantity of Product A.

When using a constraint rule with condition criteria for a product with multiple line items, the system only validates the primary line item to evaluate the constraint rule.

You must run a criteria maintenance job whenever you add, remove, or make any changes to criteria. Even if you remove a constraint rule that has criteria defined, you must run a criteria maintenance.

You can create a Constraint Rule Condition or Constraint Rule Action criteria that is based on a field from the Product Attribute Value Extension object.

To Create Constraint Rule Conditions

You must have an existing constraint rule header.

  1. On App Menu, click Apttus CPQ Admin and then click the CPQAdmin tab. The new admin console is launched.
  2. On the Products menu, click Manage Products.
  3. Search and click any product for which you want to define a constraint rule.
  4. Click Rules. The page displays different rules tab.
  5. Click Constraint Rule icon () next to the title, RULES. All the constraint rules associated with that product are displayed.
  6. Search and click the constraint rule.
  7. Fill in the required details under the IF(scope)... section. Enter a number under Condition column.
  8. Select one of the following options from Product Scope drop down. The last column changes based on the product scope you select. Enter the name in the last column accordingly.

    OptionDescription
    ProductAfter selecting, enter the name or product code of the product in the Product field. This implies that the product should be present in the shopping cart in order to meet the condition. 
    Product FamilyAfter selecting, enter a Product Family name in the Product Family field. When specified, one or more products from the specified Product Family should be present in the shopping cart in order to meet the condition. The number of products that should be present depends on the Match Rule.
    Product GroupAfter selecting, enter a product group in the Product Group field. This implies that one or more products from the specified product group should be present in the shopping cart. The number of products that should be present depends on the Match Rule.
    Product Field Set

    After selecting Product Field Sets in the product scope, an add icon () is displayed, add product fields. This implies that when the value of the field specified in the product scope matches the value of the field on the cart, the constraint rule condition is satisfied. You must add atleast one Product Field.

    1. Click the add icon ().
    2. Select a product field from the picklist.
    3. Select an operator.
    4. Define the value of the product field in Value. Each of the Product Field has onepick list value from the product object.

    The Product Field should be set up to have only one choice. If the choices are changed at a later time, the constraint rule conditions with Product Field Set specification should also be updated to have the correct values. Match Rule is not applied on Product Field Set based constraint rules. CPQ considers Match Rule as Match Any in Group by default in such case.

    Product Option Group

    After selecting this option, enter an Option Group ID associated with the bundle in the Product Option Group field. This implies that one or more products from the specified product option group must be present in the shopping cart. The number of products that must be present depends on the Match Rule.

    If you define the constraint rule in CPQ Admin, enter the option group name associated with the bundle in the Product Option Group field.

    Header LevelThis functionality is deprecated.
  9. Click the setting icon (). A pop-up is displayed. Click CONDITIONS tab and fill in the details as explained below.

    OptionDescription
    Condition NameThe name is populated automatically. You can edit the name as you desire.
    Match In Primary LinesSelecting this means the condition is met only when the condition products are among the primary lines (bundle or standalone) of the shopping cart.
    Match In OptionsSelecting this means the condition is met only when the condition products are in the option line items of the shopping cart.
    Match in Cart OptionsSelecting this means the condition is met only when the condition products are among the cart line items of the shopping cart.
    Match in LocationSelecting this means that constraint rules are executed within a location selected on the catalog. When the Sales rep selects a location and adds the condition product to the cart, constraint rule actions are executed. Upon changing the location, constraint rules are invoked again if conditions are met for the newly selected location.
    Match in Related LinesSelecting this means the condition is met only when the condition products are among the related lines (bundle or standalone) of the shopping cart.
    Match Rule

    Select one of the following choices. The value is None by default. Match count is done before applying the criteria.

    • None means that the rule condition is met if any one of the products in the product scope is selected. It is treated as Min/Max with Match Min Products as 1.
    • Match Any In Group means that the rule condition is met if any one or more of the products from the group is selected. Match Any In Group is the same as Include Min/Max with Match Min Products as 1. It is also applicable to the Product Family and Product Field Set.
    • Match All In Group means that all of the products from the group must be present in the shopping cart to meet the condition. This is applicable only to the product group and Product Family.
    • Min/Max also requires you to specify a value in the Match Min Products field.
    Match Min ProductsThis field is applicable only when you select Min/Max from the Match Rule picklist. The condition is met, when the minimum number of products specified is selected from the Product Group, Product Family, or as specified by the Product Field Set specification.
    Match Max ProductsThis field is applicable only when you select Min/Max from the Match Rule picklist. The condition is met, when the max number of products specified is selected from the Product Group, Product Family, or as specified by the Product Field set specification.

    Match Rule is applicable to product scope of type Product Group, Product Family, and Product Field Set only.

  10. Click Save.
  11. Click the flare icon () to define condition criteria. A pop-up is displayed.
  12. Click New Filter.
  13. Type a Field, an Operator, and type a Value. You can enter more than one criteria.
  14. Click Save.

You can add multiple conditions in a constraint rule. Click add icon () and follow the steps again.

You can also define condition association to define additional criteria to further filter the product scope condition. Next to IF(scope)..., select Custom from the drop-down menu. When there are more than one condition for a constraint rule, this field defines when to consider one or more of the conditions using AND/OR association. The sequence number defined in the Condition column is used as an identifier of the condition.

Few examples, you defined conditions with sequence numbers as 123, 4, 5, and 6. The following examples describe various condition association

Condition Association Description

(1 AND (2 OR 3))

Either Conditions 1 and 2  or Conditions 1 and 3 must be satisfied on the cart 
1 AND NOT 2Condition 1 is in the cart while Condition 2 is not
1 AND NOT(2)Condition 1 is in the cart while Condition 2 is not
1 AND 1Only Condition 1 is evaluated on the cart. If you have defined multiple conditions, CPQ does not evaluate the remaining conditions
NOT(5 OR 6)Neither Condition 5 or 6 are in the cart
NOT 5 AND 6Condition 5 is not in the cart, but Condition 6 is in the Cart.

Apttus recommends you to use logical operator - AND - to display the resultant record if all the conditions separated by AND is TRUE. For instance, (1 OR 2 ) AND (3 OR 4) AND 5. If you enter an invalid condition association, an error is displayed when you save the constraint rule.

You must set the Sequence for each condition or the Condition Association will be unreliable. Also, a constraint rule with only NOT in condition will not work. Example, NOT (1 AND 2).

The constraint rule conditions are created. You can now define a constraint rule action.