No records in Salesforce match your delete criteria
Salesforce Flows currently throw a fault when trying to delete records that don't exist or when deleting from an empty collection. This article highlights the frustration of this behavior and suggests a useful improvement: an optional checkbox to continue even if no records are deleted, which would simplify flow design. The key practical advice is to always verify that records exist before attempting deletion in a Flow to avoid errors.
- Salesforce Flow delete steps fail if no matching records exist to delete.
- Check collections are not empty before attempting to delete in Flows.
- Use conditions like 'Collection is empty = false' to prevent delete faults.
- An optional 'Continue if no records are deleted' checkbox would improve Flow deletes.
- Always verify record existence to avoid fault paths during deletions.
Salesforce is awesome, most of the time. The good news is it’s always improving. One feature I hope they add soon is the ability to delete 0 records. This occurs when you attempt to delete a collection that contains no records or to delete a single record that doesn’t exist. Rather than continuing to the next step, the flow’s fault path triggers with the message, “No records in Salesforce match your delete criteria”. This forces you to confirm the collection is not empty (or the record exists) before deleting it. This is quite annoying and doesn’t add any value. At least with a collection, you don’t need to set the count to the size of the collection. You can just add the condition Collection is empty = false. But regardless, a little optional checkbox on the delete step labelled, “Continue if no records are deleted” would be super super helpful. The takeaway Before deleting records in flow, be sure the records actually exist.