Salesforce made great success User will learn the record bulkification and platform governor limits
that is applied when using Lightning Process Builder. Say there is existing salesforce org with lot
of customizations like apex trigger and workflow field update. Now admin/developer is planning to
build process builder. What consideration should kept in mind before build lightning process
builder?
1. Lightning Process Builder Automation
Sathishkumar Periyasamy
@ppksathish1
Cincinnati Salesforce User Group
June 2017
2. Question
• How many of you used process builder?
• How many of you used Scheduled Action?
• How many of you having Apex Trigger and Process Builder on
same object?
• How many of you having WF Field Update and PB Update
Record on same object?
• How many of you having more than 10 process builder on
single object?
• How many of you used Visual Flow?
3. Content
• What is Process Builder?
• How to Create Process Builder?
• Types of Process Builder
• Types of actions
• Considerations
• Process Limit
• Schedule Action Considerations
• Demo
• Q & A
4. What is Process Builder?
Through process builder you can even further extend the platform to automate even
more workflow does without needing any apex code. You can easily automate business
process using point and click through lightning visual interface. A single process can also
execute multiple action group.
For example :
• You can create a record
• Update record (including parent and child)
• Posting to chatter
• Launching Flow
• Call another process builder
• And so on.
We will look each action in more detail further slide and demos.
6. Types of Process Builder
There are 2 types process builder
1. Record Changes
2. Invoke by other process builder
7. Type of Immediate and Schedule Actions
Following action can be done
• Create an Record
• Update Records - Current record or parent or child records
• Post to chatter
• Use quick action to create, update record and log an call.
• Send an email
• Submit for approval
• Launch Visual flow
• Processes - Call another flow here
• Apex - build complex business process or make external system call
8. Consideration
• Salesforce synchronous platform limitation
• Can't control execution order
• Keep trigger or process builder or workflow rule for Field Update to avoid governor limit and
unexpected results
• Each Create a Record action uses one DML statement. Each Quick Action action uses one DML
statement. Each Update Records action uses one SOQL query and one DML statement. Each Flows
action can use multiple SOQL queries and DML statements, depending on the elements that the
flow executes
• Process 200 records at time. Each 200 record reach above limitations.
• When checking reference object field value in the criteria, first should check reference
field(lookup) not null.
• For example account lookup field is empty on the Contact and only checking Account Billing
State = 'OHIO' then this will fail process builder. Should check Account not empty and checking
Account Billing State = 'OHIO’.
• Can't use logical condition in Update record action criteria rule.
• Validation rule and Trigger will fire while process builder update record but workflow rule fire
trigger once after update completed and validation rule won’t execute.
10. Schedule Action Consideration
• This section could not appear when select created or edited option. Workaround is Enable
advanced feature on the Criteria Node.
• Current Time - will take process created user time zone
• Field Value (Date Field) - Will take org time zone.
• If the schedule references a null field value, Salesforce ignores that schedule.
11.
12. Use Case 1 – Rollup Summary
Customer service manager want to know how may open activities on each Case.
13. Use Case 2 – Update Parent
and Child Record
When you update the contact email address,
system should update Account and opportunity
with contact email address domain name. Sales rep
should have ability change the domain name on the
Account and Opportunity.
14. Use Case 3 – Platform Limitation Scenario
Showing Salesforce platform limit when you have only process builder, Only workflow
field update, workflow field update with Trigger and Process builder with Trigger.
15. Use Case 3 – Platform Limitation Scenario(Con)
Process builder with Trigger vs Workflow Field Update with Trigger scenario.
16. Use Case 4 – Delete Records
When the case status is changed to “Not an Issue”, associated task should be deleted.
Note: Process builder does not support Delete Action but allow to call Apex code to delete
records.