Dreamforce Special: Hands on the New Process Builder – Actions!

Yesterday, I introduced the Process Builder. Today, I’m going to do a deeper dive and show you more of the different actions we can take with the process builder.

The process builder has some similarities with Workflow Rules. It can update fields and send emails. It can also do so much more!

So let’s exam the list of all the various actions we can take.

The Actions

Available Actions

Available Actions

There are seven actions types supported by the process builder. Just like with Workflow Rules, actions can occur either immediately or on a time-based scheduled. Some of the actions are familiar, but have been made a bit more robust.

Workflow Field Updates in the process builder is simply “Update Records.” You’ll notice there’s no “Create Task” in the action list. We’re no longer limited to only creating tasks. We can no “Create a Record” which may or may not be associated to the record firing the process.

Other actions that are available in Process Builder include Email Alerts, Launch a Flow, Quick Actions and Submit for Approval.

Flow fans may notice that all these actions are actions we can do within Flow. There’s a good reason for this. The process builder is using Flow in the background as the power horse.

Let’s take a look at each Action a bit more in Detail.

Create a Record

Workflow Rules allow us to create tasks. That’s great… and so boring. Process Builder allows us to create almost anything! THE SHEER UNMITIGATED POWER! Er.. Sorry got a bit carried away.  The Create a Record Action let’s you choose what object you want to create. The record you create doesn’t have to be related to the record the process is firing on. Want to create a new Account? No Problem. How about a new Opportunity? Go ahead, create two!

Once you chosen the object you’ll be creating you can select the fields and their values. There are two methods of setting a value. You can simply type the value in – you always want the Account number to be “42” for example. You can also populate based on the value of a field of the record that’s calling the process. The setup feels very similar to creating defaults for a publisher action.

That’s it for creating a record. It’s a very intuitive setup, although I’ve had some difficulty with multi-select picklists.

Process Builder Create Almost ANY Record

Email Alerts

We all love Email alerts with Workflow Rules. The Process Builder continues their usage. There are only two thing you need to define with the Email Alert: The Name of the Action, and the Email Alert itself. Unlike Workflow Rules where you can create the email alert from the actions are, Process Builder currently requires you to create the Email Alert first and then reference it as an action. It’s a little bit annoying, but I’m guessing it’ll get streamlined in the future.

Process Builder Email Alerts

Launch a Flow

This may shock some of you, but this is my FAVORITE action! Who needs to call Flow from a Workflow Rule when I have the power of the Process Builder! Basically, when you choose “Launch a Flow” as your action, you basically create a Flow Trigger as the rest of the action. It’s very straight forward. You choose your Flow and then set what the values of the Flow Variables will be. Remember, Flow Variables need to be at least Input only – although I tend to choose Input and Output for consistency sake and to work around a bug.

What I really like about the Launch the Flow action is the Flow Variables support type ahead. I am going to start labeling all my input and output variables with the same prefix to make it very easy to select them.

Process Builder Launch a Flow

Post to Chatter

Posting to Chatter. This is pretty nifty idea. This action let’s you post to either the record, a user profile, or to a group. You can choose to mention a person or a group, add topics, and it supports field merges. I’m planning on using this with Chatter Groups to replace some e-mail notifications. Want to be notified when x happens? Great join the x group. Want an email each time – great! Go update your own group email digest settings.

Process Builder Chatter Post

Quick Actions

The Process Builder allows you to use a Chatter Action or “Quick Action” as well. You can select an action that’s on a particular action or a global action. You can also search for your actions by Type (Create a Record, Log a Call, or Update a Record). I have a Quick Action for sales people to simply add a task that they left a voice message. I can now use that quick action within a Process. That’s pretty nifty.

Process Builder Quick Actions

Submit for Approval

Submitting records for approval through a Workflow Rule is something I’ve been wanting for years. It’s amazing how many times people forget they need to click that “submit for approval” button – or click the button before they completed all the prerequisites and get frustrated when there’s no approval process that meets their incomplete information. With Process Builder, I can force – er I mean add the user benefit of submitting the process on the behalf once the record has met certain criteria. I can even daisy-chain approval processes together by having one approval process update a field on the record which calls the process to submit to a different approval process.

With the Submit for Approval action you have two choices. You can submit to the “Default approval process” which is the same as just clicking the Submit for Approval button – or you can submit to a specific process. You can also choose the user who doing the submission and opt to ignore the Approval Process entry criteria. My favorite part is adding Submission Comments which show up in the Approval History.

Process Builder Submit for Approval

Update Records

Last, but not least, is Update Records. With Workflow Rules, we can do Field Updates. We can do the same thing with the Process Builder – but we can do SO MUCH MORE! With the Update Records action we can update CHILD records! That’s right! You have a process on the Opportunity, you can go and update every Opportunity Product!

There are a few catches here. The change has to be the same for each child record. So far, I don’t see a method for adding a formula to the action so you can have a different value set for each record. You also don’t have access to fields of the child record for dynamic values. So if you’re going to update all the Opportunity Products to have the same Discount % or pull down a value from the Opportunity to all the child records – then you’re set. If you want something more flexible, you’ll going to want to Launch a Flow.

Process Builder Update Child Records

 

Wrap Up

There’s the actions we can do with the Process Builder. You can see it is significantly more powerful than Workflow Rules. In our next post, I’ll do a little deeper dive and show you what it takes to put it all together to create your first process.

Showing 14 comments
  • Jerry Reid
    Reply

    Thanks for the great summary on the process builder!

  • Paige Spicer
    Reply

    Wonderful article! Thank you for the nice introduction. I know with the new Headless Flows, you gain the ability to update a lookup record field. Do you happen to know if the Process Builder gives you the same functionality?

    • Salesforce Wizard
      Reply

      Paige,

      Thanks for the feedback. You can updates some lookup fields with process builder, but I have had some issues on occasion selecting just the lookup field. Regardless, you can still use process builder to launch the process builder.

  • Emily
    Reply

    “Default Approval Process” seems to also bypass the entry criteria… have you found that to be the case?

  • Mike Fuchs
    Reply

    This is a great post. I’m hoping you can help me out with an error. I was able to call my flow using flow triggers from a workflow, BUT when I call the same flow from process builder (and passing along the input variables) I get this error below. Any ideas- I’m hoping it is something simple!

    Insert failed. First exception on row 0; first error: CANNOT_EXECUTE_FLOW_TRIGGER, The record couldn’t be saved because it failed to trigger a flow. A flow trigger failed to execute the flow with version ID 301c00000008s6E. Contact your administrator for help.: []

    Encountered unhandled fault when running process UpdatePracticeGood/301c00000008s6E exception by user/organization: 00Dc0000003tk28/{4}
    Source organization: 00DE0000000dkLn (null)
    Failed to find a definition id for pse.Practice_Flow_Update

    caused by element : FlowActionCall.myRule_1_A1

    caused by: Failed to find a definition id for pse.Practice_Flow_Update

    Salesforce Error ID: 1572716057-252649 (426994422)

    • Salesforce Wizard
      Reply

      Tough to say Mike. Sadly error messages in flow aren’t always the most informative. Based just on that I would be looking at the ID variables that are involved. The BEST method (right now anyways) is to use developer console. You can change the logging on Workflow to be “Fine” and then run your process. It’ll create a debug log that you can look and hopefully get a better idea.

      • Mike Fuchs
        Reply

        Thanks for your reply. I was mostly surprised as the flow works fine when triggered from a “Flow trigger” so I’m surprised the error is from the flow itself. I’ll keep playing around with it.

      • Mike Fuchs
        Reply

        One more update -it loos like my error only occurs when I’m doing flows on custom objects. When I called a flow on a standard object from process builder, it worked fine. Funny part was flow triggers (when I had access to them), allowed me to call flows dealing with custom objects. Totally bummed out!

        • Salesforce Wizard
          Reply

          That may be a complete coincidence. I have flows being called on custom objects and they work just fine. Have you tried submitting a support case?

      • Mike Fuchs
        Reply

        I should have said it from custom objects from a managed package. Looks like it is already a known issue:
        https://success.salesforce.com/issues_view?id=a1p300000008Xc4AAE

      • Mike Fuchs
        Reply

        No problem! I’m hoping you can help me real quick, as I’m a noice when it comes to Apex code. If I want to launch an autolaunched flow from an Apex Trigger, can you complete this code for me?

        Flow name is PracticeUpdate and is called from an custom object with the API name of pse_Proj_c. I want to call the flow when a new pse_Proj_c record is created and I need to pass along two input variables from fields on this object. Here is the shell of my code. I’m hoping this is simple:

        trigger CallPracticeUpdateFlpw on pse__Proj__c (before insert) {

        for (pse__Proj__c proj : Trigger.new) {

        // here is where I would call the flow. please help 🙂

        }
        }

  • Ashish Jain
    Reply

    Its very good to know about new process in summarized… its a kind if Quick review..
    could you plz give some input of my issues…
    I am getting very less no of fields in option to field update of process builder.. is it because of same custom object field i want to update which i m configuring the process builder. or any other issue not getting any clue.
    Need some suggestions…

Leave a Reply