SlideShare a Scribd company logo
Salesforce Admin Group, Trichy
Low Code Love: Salesforce
Automation Tool vs Apex Code
Kadhar Basha J
Salesforce Admin Group, Trichy
Trailblazer Community Group Leader
MST Solutions
Sundaravel J
Salesforce Admin Group, Trichy
Trailblazer Community Group Co-Leader
MST Solutions
Salesforce Admin Group, Trichy
Salesforce Admin Group, Trichy
Speaker
Kadhar Basha J
MST Solutions
Salesforce Admin Group, Trichy
• Meetup Success
• Public Interest
• Social Media promotions
• Leader contribution
• Previous meetups
• Achievement
• Admin path
Today’s Agenda
• What is a Roll-Up summary Field?
• What is the necessity of automation?
• What all are the limitations of Roll-Up
• What alternative solutions do we have?
• Demo
• Questions & Answers
• Conclusion
What is a Roll-Up summary Field?Logo
• Roll-up summary is a built-in functionality in Salesforce. They allow
you to create Sums, Counts, and more for objects that share a Master-
Detail relationship.
• Cannot use Roll-Up Summary fields to create a Sum or Count for
objects related with a Lookup field
• The Roll-up field automatically looks for the change in related records
and automatically updates the Master record.
Continued…Logo
• This can be created only when the relationship between Parent
and child is ‘Master-Detail’ Relation.
ExampleLogo
we have ‘Admin’ object, which his having a ‘Trichy’ as Child
Object. We can calculate the number of child objects exists
for the ‘Admin’ and display them in the ‘Admin’ object.
When a new ‘Trichy’ is added, the roll-up summary field in
‘Admin’ is updated automatically.
Schema DescriptionLogo
What is the necessity of automation?Logo
There are two more options to create a roll-up field without MD
relationship.
• Apex code
• Automation process
Why we choose Automation over apex code?
We can integrate different Automation tools like Process Builder and
Auto launched Flow to perform a complex process and can even call
Apex code from the tools. In short, they have made the jobs of
Salesforce Administrators easier.
Automation TypesLogo
Automation process has
divided into four different
types based on the
functionality
• Workflow
• Process Builder
• Approval Process
• Flow Builder
What all are the limitations of Roll-Up summary fieldLogo
• A Roll-up summary can be created only on records which are having
Master-Detail Relationship.
• A Master-detail relationship can’t be changed to lookup relationship
after creating a roll-up summary field on an object.
• When you refer to a roll-up summary field in a list view or report, you
can’t use certain qualifiers, including: Starts with Contains, Does not
contain, Includes, Excludes and Within.
What alternative solutions do we have?Logo
Now we can be able to create a Sum, Count, Min and Max field to
populate values on objects that do not share a Master-Detail
relationship using either Automation or Developing concepts
• Apex/Trigger
• Flow/Process Builder
Screen Flow
Auto-Launched Flow(Flow with Process Builder)
Triggered Flow
Lightning Scheduler Flow
Apex TriggerLogo
trigger ApexRollUpSummaryTrigger on Trichy__c (after insert, after update, after delete, after undelete)
{
if (trigger.isAfter && (trigger.isInsert || trigger.isUpdate || trigger.isUndelete))
{
ApexRollUpSummary.sumofMembers(trigger.new);
}
else if (trigger.isAfter && trigger.isDelete)
{
ApexRollUpSummary.sumofMembers(trigger.old);
}
}
Apex ClassLogo
public class ApexRollUpSummary
{
public static void sumofMembers(list<Trichy__c> lstOfMembers)
{
Set<Id> adminIds = new Set<Id>();
List<Admin__c> updLstOfAdm = new List<Admin__c>();
List<Trichy__c> memberList = new List<Trichy__c>();
for(Trichy__c trichy : lstOfMembers)
{
if(trichy.Admin__c != null)
adminIds.add(trichy.Admin__c);
}
ContinuationLogo
List<Admin__c> lstAdm = [SELECT Id,Name,Total_Members__c, (SELECT
Id,Group_Members__c FROM Trichys__r) FROM Admin__c WHERE Id IN : adminIds];
for(Admin__c adm : lstAdm)
{
decimal total = 0;
if(adm.Trichys__r.size() >0)
for(Trichy__c tcy : adm.Trichys__r)
{
if(tcy.Group_Members__c != null)
total = total+tcy.Group_Members__c;
ContinuationLogo
}
adm.Total_Members__c = total;
updLstOfAdm.add(adm);
}
if(updLstOfAdm.size() > 0)
{
update updLstOfAdm;
}
}
}
Auto-Launched FlowLogo
Triggered FlowLogo
Triggered FlowLogo
Challenges in ApexLogo
• Need to maintain all the insert and update events in a single
trigger for a single object (As part of best practice)
• Need to have handler logic in separate apex class.
• Mandatorily should write apex test class and have test
coverage of above 75% for and every class.
• Test class should cover positive, negative and bulk scenarios
(As part of best practice).
• Need to have trigger switch in order to turn it off in
production.
Launch
DEMO
Any
Questions
so
far
Conclusion
• Sometimes Apex code also depend on Automation process
• New version of Flow contains all those options which is available after
wrote a huge lines of code in Apex.
• Initially process builder doesn’t have “Delete” option but that would be
overcome by Flow builder
• As a Low Code Lover, I would suggest to go with Automation
Word Quiz
Low code love salesforce automation tool vs apex code

More Related Content

PPTX
Winter 22 features
PPTX
How to crack java script certification
PPTX
Salesforce Winter ’22 Release Highlights
PDF
BrightGen's Salesforce Winter 22 Webinar
PPTX
How to crack Admin and Advanced Admin
PPTX
Formstack
PDF
BrightGen's Salesforce Summer 21 release webinar
PDF
Spring 21 Salesforce Release Webinar
Winter 22 features
How to crack java script certification
Salesforce Winter ’22 Release Highlights
BrightGen's Salesforce Winter 22 Webinar
How to crack Admin and Advanced Admin
Formstack
BrightGen's Salesforce Summer 21 release webinar
Spring 21 Salesforce Release Webinar

What's hot (20)

PPT
Vf ppt (1)
PPTX
Singapore Admin Group - 5 Free Admin Tools to Make Your Life Easier
PPTX
Admin community meetup admin secrets to clear salesforce interview (1)
PPTX
Salesforce Basic Development
PPTX
Salesforce Developer Console ppt
PPTX
5 free admin tools to make your life easier - Tel Aviv, Israel Admin Group
PDF
Visual Workflow Overview
PPT
MS Dynamics CRM 2011 Technical
PPTX
Introduction to apex code
PPTX
Practical Headless Flow Examples
PPTX
SharePoint 2016 Platform Adoption Lessons Learned and Advanced Troubleshooting
PPT
Salesforce Traning Adm 201
PPTX
SharePoint 2013: Using Client-Side Rendering to color-code list cells
PPTX
SharePoint 2016 Adoption - Lessons Learned and Advanced Troubleshooting
PPTX
Intro to salesforce platform for developers
PPTX
Custom Automation Masterclass – Workshop 2: Email validation using kKckbox
PPTX
Cloud flow designer: Salesforce.com
PPT
oracle oa framework training | oracle oa framework training courses | oa fram...
PPTX
Oracle application framework (oaf) online training
PPT
Nw2004s What Is New
Vf ppt (1)
Singapore Admin Group - 5 Free Admin Tools to Make Your Life Easier
Admin community meetup admin secrets to clear salesforce interview (1)
Salesforce Basic Development
Salesforce Developer Console ppt
5 free admin tools to make your life easier - Tel Aviv, Israel Admin Group
Visual Workflow Overview
MS Dynamics CRM 2011 Technical
Introduction to apex code
Practical Headless Flow Examples
SharePoint 2016 Platform Adoption Lessons Learned and Advanced Troubleshooting
Salesforce Traning Adm 201
SharePoint 2013: Using Client-Side Rendering to color-code list cells
SharePoint 2016 Adoption - Lessons Learned and Advanced Troubleshooting
Intro to salesforce platform for developers
Custom Automation Masterclass – Workshop 2: Email validation using kKckbox
Cloud flow designer: Salesforce.com
oracle oa framework training | oracle oa framework training courses | oa fram...
Oracle application framework (oaf) online training
Nw2004s What Is New
Ad

Similar to Low code love salesforce automation tool vs apex code (20)

PDF
Programming Building Blocks for Admins
PPTX
bmarshall teaching Calculation Manager on prem
PPTX
Spstc2011 managed metadata real world
PPTX
Spstc2011 managed metadata real world
PPTX
TrailblazerDX Motihari.pptx
PPTX
Welcome Webinar Slides
PDF
Cleveland Developers: Technical Debt 10/4
PPTX
Tfs session
PPTX
TFS session
PPTX
Salesforce interview questions walkthrough
PPTX
Alternate for scheduled apex using flow builder
PDF
Looking under the hood of your org with eclipse
PDF
Get ready for your platform developer i certification webinar
PPTX
Dreamforce 2019 GG & Spring 20 release features - Halifax, Canada Community
PPT
Orcl Crmod Vs Sfdc Reporting And Analytics
PPT
Analytics: CRM On Demand vs SFDC
PPTX
CRMUG UK November 2015 - Data Migration Without Tears by Mike Feingold
PDF
Barcelona Salesforce Admins Group (7-May-2019)
PDF
Salesforce Admin Group-Barcelona-2022-07-05 In-person Meetup-BCN Admins Group
PDF
Performance Tuning for Visualforce and Apex
Programming Building Blocks for Admins
bmarshall teaching Calculation Manager on prem
Spstc2011 managed metadata real world
Spstc2011 managed metadata real world
TrailblazerDX Motihari.pptx
Welcome Webinar Slides
Cleveland Developers: Technical Debt 10/4
Tfs session
TFS session
Salesforce interview questions walkthrough
Alternate for scheduled apex using flow builder
Looking under the hood of your org with eclipse
Get ready for your platform developer i certification webinar
Dreamforce 2019 GG & Spring 20 release features - Halifax, Canada Community
Orcl Crmod Vs Sfdc Reporting And Analytics
Analytics: CRM On Demand vs SFDC
CRMUG UK November 2015 - Data Migration Without Tears by Mike Feingold
Barcelona Salesforce Admins Group (7-May-2019)
Salesforce Admin Group-Barcelona-2022-07-05 In-person Meetup-BCN Admins Group
Performance Tuning for Visualforce and Apex
Ad

More from KadharBashaJ (20)

PPTX
A Review on LWC Events for communication.pptx
PPTX
Winter'23 Release Updates.pptx
PPTX
Asynchronous Apex .pptx
PPTX
Review on Data Security.pptx
PPTX
Flow With Aura.pptx
PPTX
Conga composer
PPTX
Flow builder series i
PPTX
Tour to docgen lightning experience
PPTX
DocuSign Power Form
PPTX
Publish and subscribe platform events using flows
PPTX
Multi language support for salesforce community portal
PPTX
Simplified appointment scheduling using lightning scheduler
PPTX
Master tableau 20 in data science by solving real life analytics problems
PPTX
Qa mockup interview for automation testing
PPTX
Qa mock up interview for manual testing
PPTX
Docu sign integration with salesforce beginner learning series integration...
PPTX
Docu sign integration with salesforce beginner learning series setting up ...
PPTX
DocuSign Integration with Salesforce - Beginner Learning Series : Kick starti...
PPTX
How to reopen with intelligent predictions from tableau and einstein discovery
PPTX
Unlock your data analytics with tableau
A Review on LWC Events for communication.pptx
Winter'23 Release Updates.pptx
Asynchronous Apex .pptx
Review on Data Security.pptx
Flow With Aura.pptx
Conga composer
Flow builder series i
Tour to docgen lightning experience
DocuSign Power Form
Publish and subscribe platform events using flows
Multi language support for salesforce community portal
Simplified appointment scheduling using lightning scheduler
Master tableau 20 in data science by solving real life analytics problems
Qa mockup interview for automation testing
Qa mock up interview for manual testing
Docu sign integration with salesforce beginner learning series integration...
Docu sign integration with salesforce beginner learning series setting up ...
DocuSign Integration with Salesforce - Beginner Learning Series : Kick starti...
How to reopen with intelligent predictions from tableau and einstein discovery
Unlock your data analytics with tableau

Recently uploaded (20)

PPTX
Spectroscopy.pptx food analysis technology
PPT
Teaching material agriculture food technology
PPTX
Programs and apps: productivity, graphics, security and other tools
PDF
Chapter 3 Spatial Domain Image Processing.pdf
PDF
TokAI - TikTok AI Agent : The First AI Application That Analyzes 10,000+ Vira...
PPTX
Digital-Transformation-Roadmap-for-Companies.pptx
PDF
How UI/UX Design Impacts User Retention in Mobile Apps.pdf
PDF
Per capita expenditure prediction using model stacking based on satellite ima...
PPTX
KOM of Painting work and Equipment Insulation REV00 update 25-dec.pptx
PDF
Unlocking AI with Model Context Protocol (MCP)
PDF
Machine learning based COVID-19 study performance prediction
PDF
Advanced methodologies resolving dimensionality complications for autism neur...
PDF
cuic standard and advanced reporting.pdf
PPTX
20250228 LYD VKU AI Blended-Learning.pptx
PDF
Spectral efficient network and resource selection model in 5G networks
PDF
Electronic commerce courselecture one. Pdf
PPTX
MYSQL Presentation for SQL database connectivity
PDF
Peak of Data & AI Encore- AI for Metadata and Smarter Workflows
PDF
Build a system with the filesystem maintained by OSTree @ COSCUP 2025
PDF
7 ChatGPT Prompts to Help You Define Your Ideal Customer Profile.pdf
Spectroscopy.pptx food analysis technology
Teaching material agriculture food technology
Programs and apps: productivity, graphics, security and other tools
Chapter 3 Spatial Domain Image Processing.pdf
TokAI - TikTok AI Agent : The First AI Application That Analyzes 10,000+ Vira...
Digital-Transformation-Roadmap-for-Companies.pptx
How UI/UX Design Impacts User Retention in Mobile Apps.pdf
Per capita expenditure prediction using model stacking based on satellite ima...
KOM of Painting work and Equipment Insulation REV00 update 25-dec.pptx
Unlocking AI with Model Context Protocol (MCP)
Machine learning based COVID-19 study performance prediction
Advanced methodologies resolving dimensionality complications for autism neur...
cuic standard and advanced reporting.pdf
20250228 LYD VKU AI Blended-Learning.pptx
Spectral efficient network and resource selection model in 5G networks
Electronic commerce courselecture one. Pdf
MYSQL Presentation for SQL database connectivity
Peak of Data & AI Encore- AI for Metadata and Smarter Workflows
Build a system with the filesystem maintained by OSTree @ COSCUP 2025
7 ChatGPT Prompts to Help You Define Your Ideal Customer Profile.pdf

Low code love salesforce automation tool vs apex code

  • 1. Salesforce Admin Group, Trichy Low Code Love: Salesforce Automation Tool vs Apex Code
  • 2. Kadhar Basha J Salesforce Admin Group, Trichy Trailblazer Community Group Leader MST Solutions Sundaravel J Salesforce Admin Group, Trichy Trailblazer Community Group Co-Leader MST Solutions Salesforce Admin Group, Trichy
  • 3. Salesforce Admin Group, Trichy Speaker Kadhar Basha J MST Solutions
  • 4. Salesforce Admin Group, Trichy • Meetup Success • Public Interest • Social Media promotions • Leader contribution • Previous meetups • Achievement • Admin path
  • 5. Today’s Agenda • What is a Roll-Up summary Field? • What is the necessity of automation? • What all are the limitations of Roll-Up • What alternative solutions do we have? • Demo • Questions & Answers • Conclusion
  • 6. What is a Roll-Up summary Field?Logo • Roll-up summary is a built-in functionality in Salesforce. They allow you to create Sums, Counts, and more for objects that share a Master- Detail relationship. • Cannot use Roll-Up Summary fields to create a Sum or Count for objects related with a Lookup field • The Roll-up field automatically looks for the change in related records and automatically updates the Master record.
  • 7. Continued…Logo • This can be created only when the relationship between Parent and child is ‘Master-Detail’ Relation.
  • 8. ExampleLogo we have ‘Admin’ object, which his having a ‘Trichy’ as Child Object. We can calculate the number of child objects exists for the ‘Admin’ and display them in the ‘Admin’ object. When a new ‘Trichy’ is added, the roll-up summary field in ‘Admin’ is updated automatically.
  • 10. What is the necessity of automation?Logo There are two more options to create a roll-up field without MD relationship. • Apex code • Automation process Why we choose Automation over apex code? We can integrate different Automation tools like Process Builder and Auto launched Flow to perform a complex process and can even call Apex code from the tools. In short, they have made the jobs of Salesforce Administrators easier.
  • 11. Automation TypesLogo Automation process has divided into four different types based on the functionality • Workflow • Process Builder • Approval Process • Flow Builder
  • 12. What all are the limitations of Roll-Up summary fieldLogo • A Roll-up summary can be created only on records which are having Master-Detail Relationship. • A Master-detail relationship can’t be changed to lookup relationship after creating a roll-up summary field on an object. • When you refer to a roll-up summary field in a list view or report, you can’t use certain qualifiers, including: Starts with Contains, Does not contain, Includes, Excludes and Within.
  • 13. What alternative solutions do we have?Logo Now we can be able to create a Sum, Count, Min and Max field to populate values on objects that do not share a Master-Detail relationship using either Automation or Developing concepts • Apex/Trigger • Flow/Process Builder Screen Flow Auto-Launched Flow(Flow with Process Builder) Triggered Flow Lightning Scheduler Flow
  • 14. Apex TriggerLogo trigger ApexRollUpSummaryTrigger on Trichy__c (after insert, after update, after delete, after undelete) { if (trigger.isAfter && (trigger.isInsert || trigger.isUpdate || trigger.isUndelete)) { ApexRollUpSummary.sumofMembers(trigger.new); } else if (trigger.isAfter && trigger.isDelete) { ApexRollUpSummary.sumofMembers(trigger.old); } }
  • 15. Apex ClassLogo public class ApexRollUpSummary { public static void sumofMembers(list<Trichy__c> lstOfMembers) { Set<Id> adminIds = new Set<Id>(); List<Admin__c> updLstOfAdm = new List<Admin__c>(); List<Trichy__c> memberList = new List<Trichy__c>(); for(Trichy__c trichy : lstOfMembers) { if(trichy.Admin__c != null) adminIds.add(trichy.Admin__c); }
  • 16. ContinuationLogo List<Admin__c> lstAdm = [SELECT Id,Name,Total_Members__c, (SELECT Id,Group_Members__c FROM Trichys__r) FROM Admin__c WHERE Id IN : adminIds]; for(Admin__c adm : lstAdm) { decimal total = 0; if(adm.Trichys__r.size() >0) for(Trichy__c tcy : adm.Trichys__r) { if(tcy.Group_Members__c != null) total = total+tcy.Group_Members__c;
  • 21. Challenges in ApexLogo • Need to maintain all the insert and update events in a single trigger for a single object (As part of best practice) • Need to have handler logic in separate apex class. • Mandatorily should write apex test class and have test coverage of above 75% for and every class. • Test class should cover positive, negative and bulk scenarios (As part of best practice). • Need to have trigger switch in order to turn it off in production.
  • 24. Conclusion • Sometimes Apex code also depend on Automation process • New version of Flow contains all those options which is available after wrote a huge lines of code in Apex. • Initially process builder doesn’t have “Delete” option but that would be overcome by Flow builder • As a Low Code Lover, I would suggest to go with Automation