SIMULATION - What is the save order of processes?
See the solution below.
1
System validation rules 2
All Apex 'before' triggers.
3
Custom validation rules 4
All Apex 'after' triggers 5
Assignment rules (Leads and Cases only) 6
Auto-response rules (Leads and Cases only) 7
Workflow rules 8
Escalation rules (Cases only) 9
Parent Roll-up Summary Fields (which triggers all of the above on the parent object)
In Salesforce, there are several types of processes that can be created, including workflow rules, approval processes, process builder, and flows. Each of these processes can have multiple criteria and actions that are executed when the criteria are met. The order in which these processes are saved can impact their functionality and should be considered when creating and editing processes.
The save order of processes is as follows:
Workflow Rules: Workflow rules are the first type of process that is evaluated when a record is created or edited. They are evaluated in the order in which they are listed in the workflow rule setup menu.
Approval Processes: Approval processes are the second type of process that is evaluated when a record is created or edited. They are evaluated in the order in which they are listed in the approval process setup menu.
Process Builder: Process Builder is the third type of process that is evaluated when a record is created or edited. They are evaluated in the order in which they are listed in the process builder setup menu.
Flow: Flow is the last type of process that is evaluated when a record is created or edited. They are evaluated in the order in which they are listed in the flow setup menu.
It is important to note that if multiple processes of the same type are triggered on the same record, they are evaluated in the order in which they are listed in the setup menu. Additionally, if a process of a certain type is deactivated, it is not evaluated during the save order.
Understanding the save order of processes can be helpful in troubleshooting issues with automation and ensuring that processes are executed in the desired order.