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
Anuj Joshi 42Anuj Joshi 42 

update parent field when child is deleted

Hi All,

I have opportunity and opportunity line item. There is a field on opprtunity with comma seprated values of op[portunity line item numbers. My requirement is when I delete opportunity line item record form opp record the field in opportunity object should get updated. I want to do it with configuration. Kindly provide me solution.

Thanks
Anuj
Jainam ContractorJainam Contractor
Hi Anuj,

You can do so by the Process Builder.

Please find the below screenshots for the same:

User-added image
1. Select the Object as Opportunity Line Item

User-added image
2. Define the Entry Criteria i.e IsDeleted = TRUE

User-added image
3. Update the Opportunity record

I have used Description field on Opportunity to update and Name field of the Opportunity Line Item. You can use any as per your needs.

Please follow the steps and let me know if it works.

Mark it as the solution if it solved your purpose.

Thanks,
Jainam Contractor,
Salesforce Consultant,
Varasi LLC
www.varasi.com
Waqar Hussain SFWaqar Hussain SF
Hi Anuj,

You will need to develop an after delete trigger on Opportunity line item to update the values on opportunity. The process builder does not fire on delete event.