Recalculate All CPQ Quotes linked to the Account when Account Record transitions to a specific stage
Hello Everyone,
We have a requirement to batch re-calculate all existing CPQ Quotes whenever the related Account record transitions to a specific stage. The solution should ensure that:
- No Quote records are skipped or missed during the re-calculation process.
- No record locks occur, preventing conflicts or failures during execution.
Tried an Approach by creating a cross reference formula field on Quote and use the Same in Quote "Calculating Fields" field set which resulted in few of the Quotes are failed during re-calculation.
Thanks in Advance !
1 answer
I'd trigger this from a Queueable or Batch Apex instead of relying on the field set trick. That way you can process the quotes in smaller chunks and avoid record locking. Kick off the job in an after‑update trigger on Account when the stage changes, and use `QuoteCalculator` in Apex to handle each quote cleanly.