[SalesForce] Does the “Allow process to evaluate a record multiple times in a single transaction” flag have functional consequences

In process builder, there is a flag "Recursion – Allow process to evaluate a record multiple times in a single transaction". It's an attribute to the object to which a process/flow applies.

The Documentation states that you can use this flag to make the processes more efficient "by reevaluating a record multiple times in a single transaction". And it states "Select Yes to allow the process to reevalute a record multiple times".

What is not clear to me: is this for efficiency only (in which case: why wouldn't you always set this to Yes?) or can this effect functionality? Are there scenarios in which a set of processes and work flow behaves differently depending on this flag?

I am witnessing strange behavior in my org, that's why I am curious.

Best Answer

Yes, the flag has functional consequences. It's not there for efficiency only, it effects the functionality of a (set of) process(es).

I have found this out the hard way: the way I read the documentation was that, even if a particular process wasn't started in the same transaction, some time later a new transaction would be started that would kick off that process. But no: sometimes the process wasn't started at all, even though its conditions had been fulfilled. Setting the flag ensured that the process was started every time.

I think the Salesforce documentation on this is, to say the least, vague.

Some more on this: today I encountered scheduled flows that had not been deleted, even though they should have been. Here also, the same flag was responsible: it was set to false, and the (indeterminate) order in which processes are run caused the process to run at an inappropriate time, so it evaluated the process entry condition at the wrong time and did not delete scheduled flows.

Related Topic