My basic question is: If I have a flow that updates a Case record based on certain mutually exclusive conditions, is the best practice to have multiple Update Records elements following each other, or to rather use Assignment elements and at the end to do one large update based on all the prior Assignment elements?
I have a flow that updates custom fields on the Case object, we have moved the logic that we used in a Process Builder over to this flow. We have some custom Date/Time fields that we have created and want them to be populated by the flow, in particular we have a Date/Time Assigned and Date/Time Working. The flow also handles other automation steps for us.
The fields in this example are: Assigned to - the person to work on the Case. Date/Time Assigned - Time at which the Case was assigned. Date/Time Working - Time at which the Case started being worked on.
The idea is if someone starts working on a Case, they should assign the case to their User and change the status of the Case to Working. If the Assigned to is populated, this should populate the Date/Time Assigned with the current time. If the User changes the Status of the Case, the Date Time Working should populate with the current time.
We also have logic that says if the Owner is blank and the Status is changed, then the Owner is populated as the current User.
This means we have a scenario where a User can update the Status of a Case with no Assigned to and this should populate the Assigned to, Date/Time Assigned and Date/Time Working using two separate Update Records elements. This is how it is handled in the flow:
There are more examples of this in the same flow:
Should I replace the Update Records elements with Assignment Elements and have one Update Records element right at the end? I am not sure if processing the Assignment or Update Records elements is faster.