[go: up one dir, main page]

0% found this document useful (0 votes)
28 views2 pages

Salesforce Execution Order Guide

The document outlines the Salesforce Order of Execution for Spring '22, detailing the sequence of operations that occur when a record is created or edited. It highlights the roles of system validation, triggers, workflows, and flows, including new features introduced in API v54. Key points include the execution order of various rules and the impact of field updates on re-evaluation processes.

Uploaded by

pbaddam074
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
28 views2 pages

Salesforce Execution Order Guide

The document outlines the Salesforce Order of Execution for Spring '22, detailing the sequence of operations that occur when a record is created or edited. It highlights the roles of system validation, triggers, workflows, and flows, including new features introduced in API v54. Key points include the execution order of various rules and the impact of field updates on re-evaluation processes.

Uploaded by

pbaddam074
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 2

Salesforce Order of Execution - Spring '22 - API v54 Comments

- Validation
If record is updated in the UI, system validation includes page layout
specific settings for Edit/Read only fields
1 2a 2b 3 4 5 System validation runs every time
Load original Execute Execute all System Validation Custom validation and dupe rules only run one time
Load new values Standard System
value BEFORE save BEFORE and Custom
trigger.new Validation
trigger.old Flows Triggers Validation Rules - Flows - New in Spring '22
- Set Running Order for before-save & after-save flows for the same
object
- API 54 Changes Flows:
1. Run after Approval/Workflow Time-Based Field Updates
2. Run before Entitlement Rules, so that entitlements can include the
Does Not Save record updates that after-safe flows make
Flow triggers are executed only one time per entity per transaction.
Yes
10 9 8 7 6
Execute Execute - Triggers
Auto-Response Assignment Execute all Saves to DB Duplicate If you have multiple triggers per object, the order they fire is not
No Duplicate Rules
Rules (Leads & Rules (Leads & AFTER Triggers No Commit Block?
pre-determined
Cases) Cases)
- Workflow Rules
All active workflow rules are evaluated
Each workflow rule only runs once
Field updates are executed before all other workflow actions
11 13 Approvals are treated as workflows
Run Up to 5 More Times Run Up to 5 More Times
If field updates causes re-evaluation, all rules that did not run one
11b,c time are re-evaluated up to 5 additional times
13b,c
Workflow /Approval Rule Evaluation

- Omni Routing
BEFORE System AFTER

Process Builder Evaluation


Triggers Validation Triggers BEFORE System AFTER When work is routed and assigned, triggers, workflow rules, approval
12 Yes Triggers Validation Triggers processes, and escalation rules do not run. Once record is edited
Execute and saved again, the standard operations run
Escalation
Rules
(Cases only) Sources:
Yes Developer Docs:
11a
https://developer.salesforce.com/docs/atlas.en-us.apexcode.meta/
Field Email Alerts Immediate Field Flow Invocable Process apexcode/apex_triggers_order_of_execution.htm
Updates? Create Tasks Field Updates? Launched Process Builder
Outbound Message Updates by Process Builder Actions Spring '22 Flow Updates:
https://help.salesforce.com/s/articleView?id=release-notes.
Execution Order of Process Builders is not
guaranteed rn_automate_flow_versioned_updates.htm&type=5&release=236

Marlene Guerra-Reeve March 2022


https://www.linkedin.com/in/marlene-guerra/

20a
20 Approval & Workflow
Post Commit Logic
14 16 17 18 19 Time-Based Field Updates
Execute Criteria based Send Email
Calculate Calculate Roll-Up Only Flows API 54 and Later
Execute AFTER Save Flows API 54 + Sharing (CBS). All Commits all DML Outbound Messages
Roll-Up Summary on
Execute Entitlement Rules (Cases only) changes to sharing table to database Time-based Workflow Actions
Summary on Gran-Parent Record BEFORE AFTER
Execute AFTER Save Flows API 53 & Earlier are calculated Async Apex, Future Methods
Parent Record Flows Flows
15 Calculated Index (Search)
Salesforce Order of Execution - Spring '22

Record Change Assignment Rules See Detail View for Notes


Created/Edited
Sources:
Auto Response Rules
System Validation Developer Docs:
Rules https://developer.salesforce.com/docs/atlas.en-us.apexcode.meta/
Workflow Rules apexcode/apex_triggers_order_of_execution.htm
BEFORE Flows
Spring '22 Flow Updates:
Escalation Rules
https://help.salesforce.com/s/articleView?id=release-notes.
Apex BEFORE Triggers rn_automate_flow_versioned_updates.htm&type=5&release=236
Process Builder
Marlene Guerra-Reeve March 2022
Custom Validation https://www.linkedin.com/in/marlene-guerra/
Rules AFTER Flows

Duplicate Rules Entitlement Rules

Cross Object Formula


Save Calculations
No Commit

Update Roll-Up
Summary Fields

Apex AFTER Triggers Post Commit Logic


Send Email
Outbound Messages
Save Commit
Time-based Workflow Actions
Async Apex, Future Methods
Calculated Index (Search)

You might also like