0

If I update a field on record using Record-triggered flows, I want to know that according to the salesforce order of execution, will it cause the triggers and processes (process builders) to run again ? Will the record go through the save cycle again ?

In the developer document, I read - "Executes record-triggered flows that are configured to run after the record is saved." So I am thinking the field update done by record-triggered auto-launched flow will not cause record to go through the save cycle again.

Am I right ?

1 Answer 1

2

There are two types of Record-Triggered Flows, those that are Before Save and those that are After Save. A Before Save Record-Triggered Flow behaves like a before DML Apex Trigger; no additional save cycles will occur. An After Save Record-Triggered Flow behaves like a Process Builder/Workflow Rule Field Update/after DML Apex Trigger; the records will enter a second save cycle, triggering most of the Triggers and Order of Execution steps again (notably, see step 13: When a process or flow executes a DML operation, the affected record goes through the save procedure.).

4
  • Hi @sfdcfox, I did a little experiment to check this. I created an After Save Record-Triggered Flow That updates a boolean field 'BL' to false. Prior to that I created a Process whose entry criteria is that the boolean field 'BL' should be false and then it updates some other field. Now when I edit and save the record - The boolean field is updated to false but the process builder is not updating the other field. That means it is not getting triggered even though the criteria meets. I think After Save Record-Triggered Flow doesn't cause the record to go through save cycle again. Thoughts ?? Dec 13, 2021 at 15:45
  • @Sfdc_Spider It says also: During a recursive save, Salesforce skips steps 9 (assignment rules) through 17 (roll-up summary field in the grandparent record). A more reliable test would be a before save trigger to verify if it ran once or twice.
    – sfdcfox
    Dec 13, 2021 at 15:59
  • Hi @sfdcfox, The trigger is running twice, but the process builder is not getting executed. So in conclusion - Updates to a record through 'After Save Record-Triggered Flow' causes the triggers to run again but not the processes (process builder). Is it ? Dec 13, 2021 at 16:21
  • 1
    @Sfdc_Spider Correct. That's what I'd expect to happen, based on documentation..
    – sfdcfox
    Dec 13, 2021 at 16:46

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .