You are here:
Price Rule Considerations
Review some important considerations when you create a price rule. (Salesforce CPQ Managed Package)
Required Editions
| Available in: All CPQ Editions |
- Evaluation Events
-
- If a price rule has a calculator evaluation event of On Initialization, Salesforce CPQ runs the rule before calculating the rule’s formula fields. If your On Initialization rule contains a formula field that requires a specific value, you can run into an error. Price conditions and actions load related records and evaluate formula fields following After Calculate rules and plugin methods. Any Block Price, Discount Tier, or Term Discount relationship in a formula contains an incorrect record. You can still reference Block Price, Discount Tier, and Term Discount in a formula field, but don’t reference those relationships in the formula itself.
- Salesforce CPQ doesn’t support On Initialization, Before Calculate, or On Calculate formulas that reference the Prorate Multiplier field or any unit price other than the List Price field. The values of those fields aren’t accurate until after the rule event’s completion.
- Salesforce CPQ doesn’t support On Initialization, Before Calculate, or On Calculate formulas that reference total price fields other than component totals and package totals. Noncomponent and nonpackage totals get their values following calculation, so a price rule can’t reference them during the first calculation sequence.
- When two price rules share an evaluation event, the earliest-firing price action’s target field value isn’t usable in the other rule’s price condition or lookup queries. Salesforce CPQ evaluates all an evaluation event’s conditions simultaneously. Actions then fire sequentially for rules whose conditions were met. An action from one rule in an evaluation event can’t influence the conditions or satisfy the lookup query of another rule in the same evaluation event.
- Other
-
- When Salesforce CPQ evaluates a price rule formula, it doesn’t account for differences between the source record’s currency and the quote’s currency. For example, suppose a quote line references a USD product while the quote uses EUR. In this case, price rules targeting the quote line use the quote line’s USD price without converting it to EUR.
- When a price action without price conditions targets the Quote, the action evaluates the quote line or quote line group with the lowest Number__c value. We recommend using price conditions to ensure that your price action targets the correct record
- Price actions can target ListPrice__c or Quantity__c only if those actions send values other than null. Salesforce CPQ supports values other than null for Quote Line Quantity__c. If Quote Line Quantity__c is null, Salesforce CPQ stops the calculation for that line.
- If you’re using a source value instead of a formula, make sure that you write your dates as YYYY-MM-DD. No other date format is supported.
- Salesforce CPQ doesn’t insert records upon calculation, so it can’t have a Required By field that looks up to a quote line. If your price rule contains SBQQ__RequiredBy__c, it doesn’t fire until after a line gets saved to the database on the advanced calculator. Because of this process, price rule formulas with SBQQ__RequiredBy__c don’t always function correctly.
- If your price rule targets list price, use Original Price as the source field rather than List Price. This process helps prevent infinite calculation loops.
- Structure your price rules to evaluate as early in the calculation sequence as possible. This structure ensures that your rule sends values to as many fields as it can during one sequence. This way, you don’t have to revise your rules if you add requirements.
- Price rules targeting the Additional Discount (%) or Additional Discount (Amt) fields must
have an action that sends a null value to the other Additional Discount field.
Note On renewal generation where Renewal Pricing Method is defined as Same, you can’t manipulate these fields until the After Calculate step, because the values are calculated On Calculate. - Salesforce CPQ doesn’t execute price rules during Apex test class execution. The JavaScript Quote Calculator performs triggered calculations in an external web service requiring a callout, and Apex test classes can’t make arbitrary callouts.
- A custom metadata object can be the target of a price rule lookup field. If multiple price rules target the same custom metadata object, all price rules must target the same field on the metadata object.
- When you’re using price conditions, and a picklist field in the Field parameter then comparing against a filter value, the filter value must be surrounded by single quotes.
Did this article solve your issue?
Let us know so we can improve!

