Big Idea or Enduring Question:
How do you automatically create a record using Process Builder?
Objectives:
After reading this blog, you’ll be able to:
- Understand the basic components of Process Builder
- Learn how to auto-create a record using Process Builder
Business Use case
Corey Eridon is working as a System Administrator at Universal Containers (UC). He received a requirement to build a process that would automatically create a child case whenever a new case is created with the Case Reason – Breakdown.
Automation Champion Approach (I-do):
Because we need to create a new record, a workflow rule would not meet the needs of this requirement. Therefore, in order to automatically create a child case, Corey should use Process Builder.
Before we dive into the solution to help Corey, though, we need to first understand what is Process Builder and its components.
You can think of Process Builder as a happy medium between workflow rules and flow — it allows more automation than a workflow rule, without the advanced complexity of a flow — all with the ease of point-and-click.
However, unlike workflow rules, Process Builder allows more functionality, such as:
- Creating a record
- Updating a related record
- Posting to Chatter
- Submitting a record for approval
- And much more.
There are four basic components that should be considered when using Process Builder — a trigger, criteria, immediate action, and scheduled action.
Component | Process |
Trigger | Indicates when the action should fire – only when a record is created or anytime a record is created or edited |
Criteria | Set conditions to execute the process |
Immediate Action | The action is fired immediately |
Scheduled Action | The action is fired at a scheduled time |
To better understand Universal Containers’ requirements, let’s break down the use case by Process Builder component. This will help us conceptualize the process by defining each node and action first.
Component | Process |
Trigger | When a new Case is created |
Criteria | Case Reason – Breakdown is selected |
Immediate Action | create a Child Case. |
Scheduled Action | Not Applicable |
Before diving further, let me show you a diagram of a Process Flow at a high level. Please spend a few minutes to go through the following Flow diagram and understand it.
Let’s begin building this automation process.
Guided Practice (We-do):
There are 4 steps to solve Corey’s business requirement using Process Builder. We must:
- Define process properties
- Define evaluation criteria
- Define process criteria
- Add action – create a record
Step 1: Define Process Properties
- Click Setup.
- In the Quick Find box, type Process Builder.
- Select Process Builder, then click New.
- Name the Process and click the Tab button. The API Name will populate.
- As a best practice, always input a description.
- The process starts when A record changes.
- Click Save.
Step 2: Define Evaluation Criteria
- Click on the Add Object node to begin selecting the evaluation criteria.
- Select the Case object from the dropdown list.
- Start the process only when a record is created.
- Click Save.
Step 3: Define Process Criteria
- Click the Add Criteria node to begin defining the process criteria.
- Name the criteria.
- The criteria should execute actions when the conditions are met.
- Set Conditions
- Field: Case | Reason
- Operator: Equals
- Type: Picklist
- Value: Breakdown
- Select All of the conditions are met (AND).
- Click Save.
Step 4: Add Action – Create a Record
- Below Immediate Actions, click Add Action.
- For Action Type, select Create a Record.
- Name the action.
- Select the Case record type.
- Set Field Values:
- Row 1:
- Field: Status
- Type: Picklist
- Value: New
- Click Add Row
- Row 2:
- Field: Case Origin
- Type: Picklist
- Value: Email
- Click Add Row
- Row 3:
- Field: Parent Case ID
- Type: Field Reference
- Value: Case | ID
- Row 1:
- Click Save.
Almost there! Once everything looks good, click the Activate button. Moving forward, a child case will be automatically created whenever the Case Reason – Breakdown is selected.
Note:- Before you activate your process, you will want to make sure that you have assigned data in the correct format because Process Builder obeys validation rules. If some fields are required by using validation rules, then make sure you have added those fields. Conversely, if some fields are required on the page layout, you can ignore those fields.
Formative Assessment:
I want to hear from you!
What is one thing you learned from this post? How do you envision applying this new knowledge in the real world?
Let me know by Tweeting me at @automationchamp, or find me on LinkedIn.