You need to sign in to do that
Don't have an account?
ryepes15
How to create a sum field off formula field
I have an opportunity that is tied to a contract. An opportunity can have many contracts. The contract is tied to a custom object called Operative one orders . on the Operative one order there is a field called Order Amount. There could be multiple Operative one orders to one contract. I have a field on the contract that sums all the order amounts I need to create a field on the opportunity that sums all the order amounts on the contract(s)
1. You could implement a custom solution using a Apex Trigger that iterates through all the Contracts for a given Opportunity whenever a Contract associated with an Opportunity or the Opportunity itself is modified. Considerations of this approach
Pros
- Flexibility to implement custom business logic
- Complete control over the behaviour of summation for e.g. you could implement a filtered summation logic to sum only those contracts which are active.
Cons- Increased go to market time due to custom development
- Additional effort required to implement test code with adequate test code coverage for the implemented code which is mandatory for a production release.
- Multiple triggers on the same object and the same event could lead to unpredictable output due to no control on the trigger execution precendence.
2. You could leverage a third party Appexchange tools to help accomplish this. The following tools should help you accomplish your given requriement.- Rollup Helper (https://appexchange.salesforce.com/listingDetail?listingId=a0N30000009i3UpEAI)
- Rollup Summary Helper (https://appexchange.salesforce.com/listingDetail?listingId=a0N3000000DpbmHEAR)
Pros- Ready to use solution
- Reduced go to market times
Cons- Limited flexibility and control
- Dependency on the package provider in case of issues
Please do not forget to mark this thread as SOLVED and answer as the BEST ANSWER if it helps address your issue.