I am doing a migration project in which I have mass inserted Opportunity records into Salesforce. Our system is heavily reliant on Process Builder for important field updates, and it was required for me to turn many of these off in order to insert records. Otherwise, I'd receive "the record couldn't be saved because it failed to trigger a flow" on insert.

Unfortunately, some of these processes need to be ran now. Is there any way to mass trigger records to be updated through process builder? I have tried leaving only the process I want to be ran on, and using the Debug Console to trigger a 'fake update', by toggling a field that the process builder is listening for. This results in the error we always see, e.g. "the record couldn't be saved because it failed to trigger a flow".

Of course, I could manually replicate all the field updates that are done in the flow and build a script that performs these - I was hoping I wouldn't have to resort to that.

  • Without knowing more about what your flows do and what's needed to "trigger" them, I think t would be difficult for anyone to answer your question. If they're interactive flows, I can see where that would be problematic, but it sounds like they're the equivalent of "flow triggers" so would need DML to fire them through process builder, only you've not said what the criteria is. Is it validation that failed to trigger your flows? – crmprogdev Feb 3 '16 at 16:20
  • @crmprogdev this is part of the issue - I can't seem to find a reliable error message. this is what I'm getting in the debug log: System.DmlException: Update failed. First exception on row 0 with id 006m0000005HRMpAAO; first error: CANNOT_EXECUTE_FLOW_TRIGGER, The record couldn’t be saved because it failed to trigger a flow. – logeyg Feb 3 '16 at 17:12
  • It would seem you're going to need to go back and look at your processes for the objects types that apply to those records and figure out what the entry criteria is. If you have any that involve triggering a flow dialogue, that would be the first place I'd suggest you look. If not, then you'll need to dig deeper. Unfortunately flows don't generate debug logs in the same way triggers do. – crmprogdev Feb 3 '16 at 21:42

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.