function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Preeti Khanna 10Preeti Khanna 10 

Unable to sumup values from all child record based on certain criteria.

I have a field opportunity which is lookupfield and quotaqty on object A.
We can have multiple records for a particular opportunity field on object B which is child of object A.
I want if in object A say quota is 10 then system will sum all the qty field of object B for a particular opportunity in different records of object B.
IF sum of qty exceeds quotaqty field of object A then system should give error message that quantity exceeds 10(quotaqty field).