Cloud Kicks wants to automatically update the Status of all open child Cases to 'Escalated' whenever a parent Account's Type is changed to 'Enterprise'. An administrator is designing a Record-Triggered Flow on the Account object to handle this requirement for accounts that may have hundreds of associated Cases. Which combination and sequence of Flow elements should the administrator use to accomplish this while adhering to Salesforce governor limit best practices?
- Use a Get Records element to store the open Cases in a collection variable, iterate through the collection using a Loop element, use an Assignment element inside the loop to set the Status field and append each updated Case to a new record collection variable, and execute a single Update Records element with the new collection outside the loop.Cevap
- BUse a Get Records element to fetch the open Cases, iterate through them with a Loop element, and place an Update Records element directly inside the loop to set the Status field to 'Escalated' on each Case record during iteration.
- CCreate a Roll-Up Summary field on the Account object to aggregate the child Cases, and use an Assignment element in the flow to update the Case Status field directly through the parent account record.
- DUse a Decision element inside a Loop element to evaluate the Case Record Type, and assign updated picklist values directly without performing a Get Records or Update Records data manipulation step.
Cevap
The administrator should use a Get Records element to retrieve open Cases into a collection, use a Loop element with an Assignment element to modify field values and append each record to a new collection variable, and place a single Update Records element outside the loop.
To process multiple child records safely without exceeding Salesforce governor limits, Flow Builder elements must be bulkified. The correct approach uses a Get Records element to store child records in a collection, iterates through them with a Loop element while updating field values in memory using Assignment elements, and completes the operation with a single Update Records element placed outside the loop.
Adım Adım Çözüm
Anahtar Kavram
Flow Builder Bulkification and Element Logic