subscribe our youtube channel popup

Troubleshooting a Broken Flow in Salesforce with Simple Example

Flows in Salesforce are effective. Without writing a single line of code, they enable us to automate business processes. Using clicks rather than code, you can assign tasks, send emails, update records, and even integrate with other systems.

Despite the strength of flows, we frequently encounter a common issue: something breaks. Perhaps your flow fails silently without taking any action, returns an error, or doesn’t function as planned. It can be frustrating when this occurs, particularly if you’re unfamiliar with Salesforce.

I’ll take you step-by-step through a straightforward, approachable example of fixing a malfunctioning Salesforce Flow in this blog. I’ll go over why flows fail, how to resolve them, and best practices to prevent future occurrences of the same problems.

Grab a cup of coffee, and let’s dive in.

Reasons why flow breaks

Before jumping into an example, it helps to understand why flows fail. Here are some of the most common reasons:

  1. Missing Field Values: The flow tries to update a required field but doesn’t have data.
  2. Permission Issues: The object or field is inaccessible to the user executing the flow.
  3. Incorrect Logic: Conditions or formulas inside the flow don’t make sense.
  4. Record Not Found: This occurs when the flow attempts to update a nonexistent record.
  5. Infinite Loops : The flow keeps updating the same record, which triggers the flow again and again.
  6. API Limits : The flow hits Salesforce governor limits by attempting to accomplish too much at once.

Okay, that’s the theory. Now, let’s take a one example and fix it together.

Example Scenario: Contact Creation Flow

Imagine this: your company wants to automatically create a Contact record whenever a new Account is created. The flow should copy the Account’s name into the new Contact.

So, you build a Record-Triggered Flow:

  • When to Trigger: When an Account is created.
  • Action to be performed: Create a new Contact with details from the Account.

Simple, right?

But the moment you test it, you see an error:

Error: Required fields are missing: [LastName] 

Uh oh. The flow is broken. Let’s troubleshoot step by step.

Step 1: Reproduce the Error

The first rule of troubleshooting is reproduce the issue clearly(Perform the same action).

  1. Go to Accounts and create a new Account:
    • Name = ‘Test Company’
  2. Save.

A Contact should be created with Name = ‘Test Company’ that is what we expected. But No Contact is created and we get an error message.

So now, we have a clear problem statement:

When creating an Account, the flow fails with a missing required field error for Contact.LastName.

Step 2: Understand the Error

Salesforce is telling us: You’re trying to create a Contact, but you didn’t give me the LastName field.

In Salesforce, Contact requires LastName. It’s a mandatory field. Since our flow is only using Account Name and Phone, it forgot about LastName.

Step 3: Open the Flow and Inspect

Now let’s go inside the flow:

  1. Go to Setup → Flows.
  2. Find your flow (maybe called Create Contact from Account).
  3. Open it.

Check the Create Records element.

  • Fields being set:
    • FirstName = Account.Name
    • LastName = blank 
    • AccountId = Account.Id

Aha! We missed mapping LastName.

Step 4: Fix the Flow

Let’s fix it by giving a value to Contact.LastName. Since our Account doesn’t have a LastName field (because Accounts are companies, not people), we can simply use the Account Name.

Implementation Steps:

  1. Open the Create Records element.
  2. Add a field mapping:
    • Contact.LastName = Account.Name
  3. Save the flow.
  4. Activate the flow.

Step 5: Test Again

Now test it:

  1. Create a new Account:
    • Name = ‘Blue Star Inc.’
  2. Save.

Expected: A Contact should be created.
Actual: Success! A Contact appears with:

  • LastName = ‘Blue Star Inc.’
  • Related to Account ‘Blue Star Inc.’

The flow works. 

Step 6: Handling Paused Flow Interviews

A complete list of all flows that have failed or are paused can be accessed in Salesforce straight from Setup. Paused interviews take place when a flow is momentarily waiting, such as while a Screen Flow is awaiting user input, while an external event or platform trigger occurs, or while scheduled actions are about to take place.Failed interviews happen when a flow encounters an error that prevents it from completing successfully.

For Screen flow to Pause go to Process Automation settings in Setup and enable let users pause flow option and click on save.

It enables Pause option in flows.

Why do Flow Interviews Pause?

Flows pause for several reasons, such as:

  • Scheduled Paths: If you’ve set up a flow to wait until a specific date or time before proceeding, it may purposefully pause. You could, for instance, set up an email to be sent three days following the creation of an account. The flow will stay in a paused state until that moment comes.
  • Waiting for Platform Events: Certain flows are made to stop until a particular platform event is obtained. Consider this as the flow listening for an outside signal before continuing, such as a system message or integration update.
  • Approval or User Action Needed: The flow may also pause while it awaits human input, such as a manager’s approval, a user’s button click, or a response to a screen interaction. Until the necessary user action is finished, the flow cannot continue.
  • Faults without Exit: Sometimes an error occurs in a flow without a suitable fault path set up. Until an administrator steps in, it remains in a paused state, effectively stuck, rather than failing entirely. Adding fault paths is a best practice because of this.

How to View Paused Interviews

  1. Go to Setup → Paused Flow Interviews.
  2. Here, you’ll see a list of all flow runs that are currently paused.
  3. You can filter by Flow Name, Interview ID, or User.

Actions You Can Take

  • Resume: If the condition has been met (e.g., date/time reached), the flow can automatically resume. You may also manually resume if applicable.
  • Delete: If the interview is stuck (for example, waiting for something that will never happen), you can delete it to free up resources.
  • Debug: Open the flow in Debug mode with similar inputs to check why it paused and whether your logic is correct.

Step 7: Check for Edge Cases

Okay, the flow works in a happy path, but what about edge cases?

  • Case 1: Account with no Phone → Contact still gets created (Phone blank). That’s fine as phone field is not mandatory.
  • Case 2: Account with a long Name → Contact.LastName accepts up to 80 characters. Works fine.
  • Case 3: Account created by a user without Contact create permissions → Flow will fail.

We may use a Fault Path inside the flow to add an error message for permissions so that users see a helpful error.

Step 8: Best Practices to Avoid Flow Breakage

From this example, let’s list some best practices:

  1. Always fill out the required fields.
    Check which fields are mandatory for the object you’re creating.
  2. Test with different data.
    Don’t limit your testing to the ideal situation. Try using different users, special characters, and missing fields.
  3. Use Fault Paths.
    You can log the error or display a custom error message if an action fails by connecting a fault path to it.
  4. Add Debug Logs.
    To test with sample data and observe each step, click the Debug button in Flow Builder.
  5. Document the Flow.
    To help future administrators grasp your reasoning, give elements descriptions.
  6. Limit Loops.
    Be careful when using loops in flows. Too many iterations can hit Salesforce limits.

A Second Example: Flow Not Triggering

Sometimes, the flow doesn’t fail, it just doesn’t run.

Let’s say you created a Record-Triggered Flow on Account, but when you create a new Account, nothing happens.

Troubleshooting Steps

  1. Check Activation.
    • Is the flow activated? Draft flows don’t run.
  1. Check Entry Conditions.
    • Maybe you set the condition: Industry = Banking.
  • If your test Account doesn’t have Industry = Banking, the flow won’t run.
  1. Check Object Permissions.
    • Does the user have permission to create the Contact?
  2. Check Trigger Timing.
    • Did you set the flow to run After Save or Before Save?
    • For creating related records, it should be After Save as it requires Id.

Fixing these usually resolves the issue.

Step 9: General Flow Debugging Tools

Salesforce gives us some helpful tools:

  • Debug Button (in Flow Builder): You can test the flow with particular inputs and view step-by-step results by using the Debug Button in the Flow Builder.
  • Error Emails: Salesforce may send an email to the administrator informing them of a flow failure.
  • System Debug Logs: To capture detailed logs of flow execution, navigate to Setup → Debug Logs.
  • Flow Interviews: To view active flows that are stalled while waiting, look for Paused Flow Interviews in Setup.

Step 10: Documenting the Fix

Whenever you troubleshoot, always document what you fixed. For our example, documentation might look like this:

  • Issue: Flow failed with error LastName required when creating Contact.
  • Cause: Flow did not map LastName field.
  • Fix: Added mapping Contact.LastName = Account.Name.
  • Testing: Verified with Accounts Blue Star Inc. and Test Company. Contact created successfully.

This helps future admins understand what was done and why.

Step 11: Takeaways

Flows are powerful but fragile if not tested well. The key lessons are:

  • Always check required fields.
  • Use debug mode before activating.
  • Handle faults gracefully.
  • Document your flows.

By following these steps, you’ll find that troubleshooting a broken flow becomes much easier and maybe even fun

Conclusion

In this blog, we walked through a very simple but realistic example of troubleshooting a broken Salesforce flow:

  • We built a flow to create a Contact when an Account is created.
  • It broke because of a missing required field (LastName).
  • We fixed it by mapping Account.Name → Contact.LastName.
  • We tested again and confirmed it works.
  • Finally, we learned some best practices to avoid such breakages in the future.

It doesn’t have to be difficult to figure out troubleshoot flows. You can resolve the majority of problems fast if you maintain your composure, carefully read the error, and test each step.

Don’t freak out the next time your flow stops. Simply keep this tale in mind, launch Debug, and begin asking: What’s missing? What is necessary? What is actually taking place here?

Happy Flow Building! 

Satyam parasa
Satyam parasa

Satyam Parasa is a Salesforce and Mobile application developer. Passionate about learning new technologies, he is the founder of Flutterant.com, where he shares his knowledge and insights.

Articles: 55

Leave a Reply

Your email address will not be published. Required fields are marked *