Too Many SOQL Queries

When I first started with Process Builder, this error drove me crazy. I have no idea where my process broke, based on this error message alone.

In protest, I would delete the entire process (that'll show 'em!), and build what I needed via Formula Fields and standard Workflow rules. However, I spent more time each week on data clean up than it took me to build the process initially. Embarrassing…

Since then, I've learned that error can typically be attributed to three causes:

  1. Process Builder is being asked to do too much at once.
  • Updating fields on more than one object at a time
  • Updating multiple records multiple times in a single transaction

Solution: Use the Scheduled Action and schedule an hour between object updates.

Before:

After:

  1. The filter on records to update is too broad
  • One filter criteria using "Starts With", "Ends With" or "Contains"
  • One filter criteria of "Is Null" on a field that should not be null in 9/10 situations

Solution: Filter, Filter, Filter -  make your criteria more specific

Before:

After:

soqlquerypic4.png
  1. The recursion button is checked somewhere on accident
  • Proceed with extreme caution on this one. For most Processes built for TaskRay - recursion is unnecessary.

Solution: Uncheck the recursion box

Before:

After:

soqlquerypic6.png

The automation of Project creation via Apex and Process Builder can drastically reduce the number of user clicks from "Will anyone care if I skip this?" to "I'm out of things to do, I wonder if my boss will let me leave?" Happy Users make Happy Admins!

If you are still seeing this error on a TaskRay process and have tried all three of the above suggestions, feel free to reach out to us at support@bracketlabs.com.  We're here to help!

Happy Admining!

Relevant Trailheads

Automate Basic Business Processes with Process Builder
Learning SOQL

Help Articles

Too Many SOQL Queries
SOQL