By Carlos Gallardo
Last month, we went over the advantages of using roll-up summary fields in Salesforce. Roll-up summary fields are a great tool for streamlining your data reports. This time, we’ll cover two solutions on the Salesforce App Exchange that make roll-ups even more helpful.
As mentioned previously, when creating a roll-up summary field that summarizes data from one object to another, the two objects need to be connected by a Master-Detail Relationship. If two objects are related by a Lookup Relationship instead, creating a roll-up summary field will not be possible. How can we resolve this? Rollup Helper and DLRS are both great options to take roll-up summary fields beyond this native restriction.
Introducing Rollup Helper
If you want the best solution for the roll-up summary field master-detail relationship limitation, Rollup Helper is your answer. Rollup Helper allows Salesforce Admins to create roll-up functionality by identifying a source object/field and a target object/field between two objects connected by a Lookup Relationship.
Rollup Helper’s documentation and help section is readily available within the app in your Salesforce org. The app’s step-by-step setup is straightforward–new and veteran Salesforce Admins alike will be able to easily install and begin building roll-ups. Roll-up creation covers all the bases, from allowing data sort order, to summarizing by Max, Min, Count and Sum operators, and even building filter criteria. Furthermore, it’s possible to enable real-time calculation.
Is Rollup Helper Worth the Price?
Although clients have used this tool and seen great benefits, it does come at a cost. While the app is available for download from the AppExchange for testing, it has a limit of 3 roll-ups and no real-time enablement unless clients upgrade to the Enterprise Edition. *Update: real-time functionality is now standard with the free version of Rollup Helper! If you feel comfortable with the Rollup Helper UI and roll-up setup, then do consider your options and test! This is especially true if you are in a Large Data Volume environment.
Meet the Declarative Lookup Rollup Summary Tool (DLRS)
If Rollup Helper is not an option due to the license cost, then your next best option is the Declarative Lookup Rollup Summary Tool (DLRS). This free tool has been a real Lookup Relationship roll-up solution for many NGO Connect and Advancement Connect clients. New releases continue to offer bug fixes and enhancements as well.
In comparison to Rollup Helper, there is no clean-cut UI to create each rollup. However, robust documentation makes it easy to install the app and quickly build new rollups. DLRS comes with all the functionality you can expect–run rollups in a Scheduled, Real-time, Developer, and even Process Builder mode. You have access to field sorting and operators from “Sum” and “Average” to First/Last. Also, you can insert your own SOQL Statements to make filtering comprehensive. Did I mention this is all free?
DLRS in Action
A perfect business case scenario for DLRS–roll-up an Account record’s “Last Hard Credit Amount” from the Giving (Opportunity) object. With standard roll-up summary fields, you can roll-up from Giving to Account object, and identify the “Max Close Date” on a completed Giving record. However, can you pull the “Closed Amount” instead?
With DLRS, you identify the records you want to filter on, by inserting your own SOQL statement in the “Relationship Criteria” field. For example, Giving records with “Completed Stage.” Then, when it comes to the sorting and aggregate operator, select “First” as the Aggregate Operator. Subsequently, insert “Close Date DESC” on the “Field To Order By” in the DLRS record. After this, run a mass recalculation or scheduled recalculation overnight in order to process all your Giving records for each Account.
In addition, DLRS lets you recalculate through filters on the Parent Object you are rolling up. If you do not want to mass recalculate all account records, you can easily write a SOQL query to run the recalculation only for specific Account records.
Does DLRS Fit Your Needs?
When executing any third-party app, it is essential to consider your org’s data volumes and reference Salesforce Governor Limits. Thankfully, DLRS was built with the intent to be lightweight and flexible. Salesforce Developers have the ability to develop on top of the tool to process millions of records with no issue.
All in all, DLRS is a special tool that allows your organization to grow. With loads of functionality for a free app, DLRS enables you to make the most of roll-up summary usage between lookup relationship objects.
Learn more about DLRS through these links:
- Get Started with DLRS: https://github.com/afawcett/declarative-lookup-rollup-summaries/wiki
- DLRS Technical Documentation and Package Release History: https://github.com/afawcett/declarative-lookup-rollup-summaries#packaged-release-history
Carlos Gallardo is a Senior Consultant for NGO Connect and Advancement Connect. Passionate about all things roundCorner and Salesforce, Carlos also supports projects as a data migration specialist, business analyst and system administrator.
*Editor’s Note: This post was updated for accuracy on October 12, 2017.