This tool has had a steady number of releases last year, containing a few bug fixes and tweaks. This Spring’15 release contains a few enhancements i’d like to talk about in more detail in this blog. So lets get started with the list…
- Support for Count Distinct rollups
- Support for Picklist / Text based rollups via Concatenate and Concatenate Distinct operations
- Support for Rolling up First or Last child records ordered by fields on the child such as Created by Date
- Support for Lightning Process Builder
UPGRADE NOTE: The Lookup Rollup Summaries object has some new fields and pick list values to support the above features. If you are upgrading you will need to add these fields and pick list values manually. I have listed these in the README.
The following sections go into more details on each of the features highlighted above.
Support for Count Distinct rollups
If you want to exclude duplicate values from the Field to Aggregate on the child object select the Count Distinct option. For example if your counting Car__c child records by Colour__c and it has 4 records, Red, Green, Blue, Red, the count would result in 3 being stored in the Aggregate Result Field. You can read more about the original idea here.
Support for Picklist / Text based rollups
The rollup operations Sum, Min, Max, Avg, Count and Count Distinct operations are still restricted to rolling up number and date/time fields as per the previous releases of the tool.
However this version of the tool now supports new operations Concatenate and Concatenate Distinct that support text based fields. Allowing you to effectively concatenate field values on children into a multi-picklist or text field on the parent object record.
By default children are concatenated based on ascending order of the values in the Field to Aggregate field. However you can also use the Field to Order By field to specify an alternative child field to order by. You can define a delimiter via the Concatenate Delimiter field. You can also enter BR() in this field to add new lines between the values or a semi-colon ; character to support multi-picklist fields. You can read more about the original idea here.
Support for Rolling up First or Last child records
By using the new First and Last operations you can choose to store the first or last record of the associated child records in the parent field. As with the concatenate feature above, the Field to Aggregate is used to order the child records in ascending order. However the Field to Order By field can also be used to order by an alternative field. Original idea here.
Support for Lightning Process Builder
To date the tool requires a small Apex Trigger to be deployed via the Manage Child Trigger button. With added support for Lightning Process Builder actions. This allows rollup calculations to be performed when creating or updating child object records. Sadly for the moment Process Builder does not support record deletion, so if your rollups require calculation on create, update and delete, please stick to the traditional approach.
To use the feature ensure you have selected Process Builder from the Calculation Mode field and specified a unique name for the rollup definition in the Lookup Rollup Summary Unique Name.
Once this is configured your ready to add an Action in the Process Builder to execute the rollup. The following Process shows an example configuration.
As you’ve seen from some of my more recent blogs, i’m getting quite excited about Process Builder. However i have to say on further inspection, its got a few limits that really stop it for now being really super powerful! Having support for handling deletion of records and also some details in terms of how optimal it invokes the actions prevent me from recommending this feature in production. Please give me your thoughts on how else you think it could be used.
February 17, 2015 at 1:14 am
Fantastic tool! Very awesome update supporting the string concatenation =)
Once Process Builder ever supports “deletions”, that will be awesome for all sorts of use cases!
February 17, 2015 at 8:24 am
Thanks Doug. And yeah case of close but no cigar with process builder! One to watch as you say!
February 18, 2015 at 11:05 am
Wouldn’t Process Builder extend to deletions using a Flow? I know it’d not be generic in the sense that this tool is, but still?
February 18, 2015 at 11:07 am
As far as I know Flow is only called by Process Builder and thus cannot be invoked by any other way relating to record manipulation.
February 17, 2015 at 1:34 am
These new features are great. Just last week, I was implementing the concatenation operator using traditional trigger means for a client.
Last night, I was playing around with the process builder. I kept thinking it was flows combined with workflow put in one place. It’s workflows 2.0 with if-then-else logic. Having the ability to kick off automated flows, invoke the “invocable” apex, and creating chatter posts is nice. The first thing I tried was seeing if I could use the deleted field to trigger an action because it showed in the list of fields and it let me save the process. However, the process didn’t do anything when the record was deleted. With record creations using 1 dml statement and other limits, it’s hard to use this in general scenarios.
Anyway, thanks for another great post.
February 17, 2015 at 8:26 am
Yeah I hear yah, i am quite disappointed and very surprised at process builder not supporting bulkification (at least not in all cases).
February 17, 2015 at 3:03 am
Andy, this is truly amazing – many thanks for all of your hard work – this is an invaluable tool for the Community!!!
February 17, 2015 at 8:26 am
Our very welcome Jen, thanks for the motivation and design input on this one!
February 17, 2015 at 6:21 am
The package is just awesome and inspirational… Please keep up the excellent work….
I have a quick question though and I am sure that I might be doing something wrong here….
I upgraded the package to the New Release and added the new fields and the new Picklist Values too, I am trying to Roll up the Amount (Currency field) from the “First” Payment (Custom Object) to the “First Payment Amount” (Currency Field) on the Contact Object.
But I am getting this Error message “Error:Master and detail fields must be the same field type (or text based) for First or Last operations”
Both the fields “Field to Aggregate” and “Aggregate Result Field” are Currency fields, are the Currency fields not supported ?
Thanks and once again Great work…..
February 17, 2015 at 1:22 pm
Your very welcome! RE: Currency fields. This should be possible, can you raise it on the GitHub issues list please, and a screenshot of your rollup def and i’ll take a look.
June 18, 2015 at 9:15 pm
Ram, did you solve this? I am getting the same issue on a date/time field.
June 18, 2015 at 11:57 pm
It was a bug and which was fixed in the following release…. for your reference here is the link to the issues page where it was discussed in detail and you should be posting your question in the issues page with snapshots… Hope it works out for you..
February 17, 2015 at 9:17 pm
Reblogged this on SutoCom Solutions.
February 26, 2015 at 2:26 am
Reblogged this on Force School.
February 26, 2015 at 2:26 am
Reblogged this on Force School.
Pingback: Extending Lightning Process Builder and Visual Workflow with Apex | Andy in the Cloud
March 9, 2015 at 3:49 am
Could you please direct me to an example of this fabulous tool rolling up Opportunities to each of the Contacts associated via the Contact Role object?
March 9, 2015 at 2:38 pm
I don’t know of a specific example for this, if you check the Readme in the repository it has links to other blogs, one on account hierarchies that might give you some ideas. You can also raise a github issue on the repository to ask this question. I am also planning on creating a Salesforce Community Group soon.
March 12, 2015 at 7:47 pm
Very excited about these enhancements! I’ve installed 1.19 and I’m not seeing any of the new changes. My installed packages reflect that I have 1.19 successfully installed but I don’t have any of the drop down options. Am I missing something?
March 12, 2015 at 8:56 pm
Yes, when upgrading you need to manually create the picklist options and update the layout, take a look at the blog and install notes for v1.18 https://github.com/afawcett/declarative-lookup-rollup-summaries/blob/master/README.markdown
March 16, 2015 at 3:23 pm
Quick question. I added the new fields from the README for 1.18 before installing 1.19. What help text did you use for the new fields (Lookup Rollup Summary Unique Name, Concatenate Delimiter, Field to Order By )?
Separately, what is the rationale/use of the Lookup Rollup Summary Unique Name field?
Thanks! Love this tool so much!
March 16, 2015 at 3:39 pm
I realized that 1.19 actually created the fields I had just added myself, complete with help text. So, it appears my first question has been answered.
March 16, 2015 at 8:20 pm
Ah yes of course, they are just missing from the layout not the object once you have upgraded, doh.
March 16, 2015 at 8:19 pm
Help text can be found on the .object file for the object see source files in github repo. The unique name is for use when running rollups via Process Builder. Glad your enjoying the tool! Thanks
March 19, 2015 at 3:59 pm
I just installed Declarative Rollups For Lookups in a sandbox, and I can’t get past a splash screen in the “Lookup Rollup Summaries” tab that says, “Welcome – Overview: This is a tool that helps address a current platform limitation around rollup summaries. Specifically the inability to do rollup summaries between lookup relationships. This is possible between master detail relationships using the declarative mode of Force.com, but not between lookup relationships. You can read more about the tool and watch a video demo by reading this blog. Release details can be found here.” How do I actually get into the area where I can start working with the tool?
March 20, 2015 at 11:16 am
Scroll down to the bottom of the page and click Continue
March 26, 2015 at 2:45 pm
D’oh! Thanks! 😀
April 2, 2015 at 3:14 pm
Andrew, this is awesome. Can you tell me more about “some details in terms of how optimal it invokes the actions”? Are you saying we don’t have that information or that we do and it isn’t great?
April 2, 2015 at 3:17 pm
At the time it didn’t appear to call the action on bulk, while their are some corner cases where it doesn’t bulkifiy the use of it in this context is safe.
April 2, 2015 at 3:21 pm
Oh okay. If I understand correctly, the lightning process builder doesn’t call that action in bulk. Does that apply to all apex custom actions?
April 6, 2015 at 12:28 pm
It does most of the time, depend on complexity of parameters, my examples work in bulk
April 16, 2015 at 8:00 pm
The latest version – fantastic.
I would organisation using the non profit data model.
I have a rollup that counts the number of contacts related to an organisation/account.
However, I have contacts that is in the database with a non profit 1:1 relationship. I.e. the contact’s account/Organisation is themselves – When I edit that record to change the organisation to a “real” organisation I get the following error.
Error:Apex trigger dlrs_ContactTrigger caused an unexpected exception, contact your administrator: dlrs_ContactTrigger: execution of AfterUpdate caused by: System.DmlException: Update failed. First exception on row 1 with id 0019000001JTyipAAD; first error: ENTITY_IS_DELETED, entity is deleted: : (dlrs)
Where 0019000001JTyipAAD is the ID of the “hidden” organisation record associated with the contact
Once I turn the rollup off the process works fine.
any thoughts on where to look to try and solve this one?
April 16, 2015 at 8:03 pm
Can you raise this on the GitHub issues list please, it might also be worth posting it in the new Salesforce Community Chatter Group (see link in Readme).
April 16, 2015 at 9:28 pm
Will do – about time I learnt all about GitHub
April 27, 2015 at 2:01 pm
I like this tool and have installed up. But, for various reasons I needed to remove it. But, it doesn’t seem to be removed because now my customer portal users are receiving this message when they update their account and contact info. How can I completely uninstall the app?
Apex script unhandled trigger exception by user/organization: 0051400000BfoEE/00D30000001GKjo
dlrs_ContactTrigger: execution of AfterUpdate
caused by: dlrs.SObjectDomain.DomainException: Permission to access an dlrs__LookupRollupSummary__c dennied.
Trigger.dlrs_ContactTrigger: line 7, column 1
April 27, 2015 at 9:32 pm
Sorry you need to uninstall, would love to know why sometime. Before you uninstall the package, be sure to visit each roll up and click the Manage Child Trigger button a click Remove. Not you only need to do this once for a given Child object, so if you have two rollups for the same Child object, just clicking Manage Child Rollup and Remove once will suffice. After this you can go to Installed Packages and a remove.
April 28, 2015 at 11:45 am
Doh! I already uninstalled the package before doing that. If I re-install will it see the previously gen’d triggers? Re: the reason for uninstalling it, one word : Management
April 28, 2015 at 1:02 pm
If you uninstalled the package I am surprised to see errors from the triggers as they form a dependency that would block uninstall of the package and list the triggers asking the user to remove them. What was it management was not keen on, it being open source?
April 28, 2015 at 7:10 pm
We have installed and set up this tool in sandbox #1 and it works great! Now we need to migrate the same set up to sandbox #2. What’s the best way to do this? Thanks!
April 28, 2015 at 9:08 pm
You can use Changesets to move the trigger and test classes, and use data loader tools to move the config, or if you only have a few rollups just repeat the process again tbh. It is on the enhancements list to improve this, possibly using the upcoming Summer 15 custom meta dada types…
May 4, 2015 at 6:57 am
I have moved this to a new org; had to setup a new remote site in Sandbox, and was able to import my rollups, however I am unable to see the VF page with Look Rollup summaries (List View). Also, did not see any spefici trigger or classes to migrate via change sets. Any ideas?
May 4, 2015 at 6:58 am
Have you assigned the permissions sets?
May 6, 2015 at 3:11 pm
do you know if there’s any way to aggregate values with the Rollup Tool within the same object?
E.g. I like to have Parent = Campaign and Child = Campaign where ParentId = Id an summarize some number values on the Parent.
I found no easy way. Maybe there’s some trick that you can propose.
May 6, 2015 at 3:22 pm
Yes you can, take a look at the account hierarchy blog linked from the readme file for inspiration.
May 6, 2015 at 3:51 pm
Thanks! Will have a look.
May 20, 2015 at 4:43 pm
Your app is awesome!
I am getting the following message when I try to deploy or remove:
HomePageController.t1 System.NullPointerException: Attempt to de-reference a null object Class.HomePageController.t1: line 69, column 1
Could the reason be that not all the Parent objects have an associated child object?
May 21, 2015 at 7:05 am
This looks like a problem in another unrelated test to the tool. The tool (due to a platform requirement) has to run ALL unmanaged apex test classes in the org when you deploy or remove its own triggers. So if you look closely at the error message you should be able to identify the failing Apex test in your org and fix it, then try again.
May 20, 2015 at 7:13 pm
Hi Andy. First of all, thank you so much for your contribution. I love the rollup tool. I’ve been using it for a while now, but just noticed an issue. I have a real-time rollup on Tasks as the child and Contacts as the parent with the WhoId as the relationship. The rollup simply counts the number of Task record Ids for the parent Contact. We use DemandTools to merge duplicate Person Accounts which works great, but for some reason my rollup isn’t firing when the child Tasks for the merged Person Accounts (and parallel Contact records) are updated to reflect the master record WhoId. I’ve verified that the WhoId on the Task record does in fact update to the master Contact record of the merge, but the rollup field isn’t updated. Any idea why this is happening. Sorry if this isn’t the appropriate place to ask this question.
May 21, 2015 at 7:09 am
No worries, typically questions get raised on the GitHub Issues page for the tool or recently in the Salesforce Sucesss Chatter group (linked on the README). So it might be worth raising in the Chatter group to see if others have come accross this. As quick thought i’m wondering if the tool is falling into this platform behaviour, https://www.salesforce.com/us/developer/docs/apexcode/Content/apex_triggers_ignoring_operations.htm
May 21, 2015 at 2:43 pm
Yep. Bullet point 2: “Cascading updates of child records that are reparented as a result of a merge operation”. BOOOO! Thanks for the direction Andy.
May 20, 2015 at 7:43 pm
Amazing tool, have not yet tried but the article describe it very amazing!
Is it possible also to track something on User object? For example I want to know the number of open cases in ownership of a user?
May 21, 2015 at 7:06 am
Yes this should be possible via the OwnerId relationship on the Case object. https://www.salesforce.com/developer/docs/api/Content/sforce_api_objects_case.htm
June 16, 2015 at 11:51 am
Hi Andy, I would be grateful if you could help me
I’ve been validating deployment (custom trigger and test class) from our sandbox into production, but I’m getting an error, that there has been an existing apex code coverage error and classes giving me that error are related to Declarative Lookup Rollup Summaries Tool:
dlrs_c2godaTransactionTrigger, Details: Test coverage of selected Apex Trigger is 0%, at least 1% test coverage is required
dlrs_c2godaTransactionLineItemTrigger, Details: Test coverage of selected Apex Trigger is 0%, at least 1% test coverage is required
dlrs_c2godaBankStatementTrigger, Details: Test coverage of selected Apex Trigger is 0%, at least 1% test coverage is required
Please let me know how I can get around that
June 18, 2015 at 7:47 am
Can you regenerate the test class with the latest version via mange child trigger button, the test code should error with a message telling you what the problem is.
June 17, 2015 at 12:47 pm
I have just created a rollup in production (we have the first version installed) and now when I logon to salesforce as it tells me insufficient privileges error at the home page.
I have all the necessary permissions, although not an admin I do have all permissions.
This has happened in sandbox also after I upgraded that one to the latest version and created a few rollups, it not shows me an insufficient privileges error upon logon and I am admin in sandbox
am I missing something?
June 18, 2015 at 7:49 am
Can you raise this on the GitHub site issues list and it might be worth posting in the chatter group see link in readme file for further support from the community. Otherwise I will try to take a look as soon as I can. Some more details and screenshots will be useful. Thanks
June 19, 2015 at 8:02 am
Hi This was ressolved as a permission setting I was given in salesforce
June 19, 2015 at 8:03 am
Can I ask, we currently have version 1.3 installed….can we jump straight to the latest 2015 release from this?
July 3, 2015 at 3:50 pm
We just upgraded to the latest version but cannot deploy a trigger as its asking for an insert of a record. I have a custom object called Assignment__c and the field is called bill_rate__c which is the error message asking that there has to be a record inserted to bill rate to enable the code coverage of the trigger to work
July 4, 2015 at 5:32 am
Take a look at this Wiki page i just posted up this should help describe whats going on and approaches to fix it. https://github.com/afawcett/declarative-lookup-rollup-summaries/wiki/Challenges-with-Code-Coverage
July 6, 2015 at 9:25 am
I am new to writing triggers so am stuck in amending the one but adding in a value for the Bill_rate field which the wiki pages suggest as I cannot deploy the rollup trigger from sandbox via a change set
July 6, 2015 at 1:00 pm
Hi sorry Nick, I am adding some new features which will hopefully make this easier, watch out for the next update within the week. If not raise something on the chatter group and ask for help there.
July 6, 2015 at 1:09 pm
Managed to solve it but adding some amendments tot he class trigger to solve the error I was getting and it deployed and worked well, thanks for your help
July 7, 2015 at 11:56 am
Great my new release should make customising the trigger test code easier in the future btw
July 10, 2015 at 8:29 pm
Hi Andy – I am using your Declarative Lookup Rollup Summaries tool and recently hit a snag. I am rolling up information from Accounts to a Custom object named Buildings but realized that one of our Account record types does not contain the Lookup relationship between Accounts and Buildings causing an error message preventing an Account record from being created. Has anyone report this use case?
July 11, 2015 at 8:42 am
No not heard about this, what’s the error message?
July 30, 2015 at 7:47 pm
Hi Andy, I am using the Lookup Rollup tool, and I do love it! For one of my rollups, I am using the “Relationship Criteria” and the “Relationship Criteria Fields” fields to filter my data. I’d like to be able to filter based on another object’s value through traversing to that object, but am not sure if this is supported by your tool. For example, my child object includes a lookup to product. I need to filter on the product. Instead of just filtering on the Salesforce ID of one product (which is my lookup field), I’d like to be able to filter on the Name of the product so I can exclude products where the naming convention matches specific criteria. To do this, I’m using this syntax in the Relationship Criteria field: Object API Name__r.Field Name ‘XYZ%’. Is this something that is currently possible? Or, does the tool not support this functionality at this time?
July 30, 2015 at 8:23 pm
thanks glad you like it! The tool monitors the criteria fields to optimise when the roll up is calculated or not, with indirect fields this is not possible, so sadly not for now, feel free to raise an enhancement
July 31, 2015 at 1:11 pm
Thanks Andy! I thought that might be the case, but just wanted to be sure. I’ll create an Enhancement request.
August 1, 2015 at 2:00 am
First of all, thanks for this tool! It is a godsend! I already have a bunch of custom rollups in place that are running smoothly.
I recently created 2 rollup summaries to keep track of “First Gift Amount” and “Last Gift Amount” in my Account object. My rollup settings are as follows:
I’m using Salesforce – NGO Connect:
Parent Obj: Account
Child Obj: Opportunity
Relationship Field: AccountID
Field to Aggregate: rC_Giving_Closed_Amount__c
Field to Order By: CloseDate
Aggregate Operation: First (Last)
Aggregate Result Field: First_Gift_Amount__c / Last_Gift_Amount__c
Calculation Mode: Realtime
Calculation Sharing Mode: User
Roughly half of my account records get updated, while the others still have blank fields. Clicking on the Calculate button doesn’t do much. Curiously I have some records where the First Gift Amount field gets updated and the Last Gift Amount field doesn’t get updated, and vice versa.
I also have similar rollups this time for First and Last Gift Dates and those are working smoothly with all records being updated (Field to Aggregate: CloseDate, no Field to Order by).
Hope this gives you enough to go on, and I look forward to hearing from you. Thanks!
August 1, 2015 at 11:13 am
Thanks, I see you have also raised on GitHub, will take a look…
June 9, 2016 at 7:05 pm
Hi Ramon, can you elborate on the steps you made to add First Gift Amount?
August 12, 2015 at 8:24 pm
Hi Andy – Absolutely love the new release! It’s already helped me replace a few problematic apex triggers that I inherited. Not to be too picky, but when using a comma as the concatenate delimiter, is there any way to include a space after the comma?
August 12, 2015 at 8:48 pm
Check the GitHub issues list, i think this has been mentioned here.
August 13, 2015 at 3:02 pm
Love this tool. Am having issues scheduling any with upgraded version on production. Does not create schedule items. AM system admin with full permissions. Any thoughts why?
August 13, 2015 at 5:39 pm
Thanks! Can you try posting on the chatter group for help, either myself or others can respond
August 13, 2015 at 6:08 pm
Would love to – how do I get to the Chatter Group?
August 14, 2015 at 3:09 pm
I have been to the chatter group but lost the link. Can you please add it here? Maybe put it on the page for future reference>? thanks
August 14, 2015 at 3:09 pm
It’s on the readme in the repo
August 14, 2015 at 6:49 pm
Thanks Andy. I am having an issue with an invalid field. If I am using a formula field on my child that references the parent, is it invalid due to recursion issues? thanks
August 15, 2015 at 11:43 am
Hard to tell without nowing more. Can you post more details on the chatter group?
August 17, 2015 at 12:18 pm
Sure Andy – you can see the thread there now, under my username John Hyaenidae. Thanks
August 18, 2015 at 7:17 am
Hi Andrew – been on here before, still think this tool is the most amazing ever! However having an issue with one I have set up currently… it is to roll up a field on certain child records to a text field on the contact but it has been creating duplicate contact records – sometimes up to 30. Why would that be? These contacts are being created and when the rule runs it appears to create them automatically 30-40 times. I have since deactivated the rollup summary, but is there anything I can do to prevent the duplicates happening? Or can I add additional filters. Any help greatly appreciated – thanksso much
* Auto Generated and Deployed by the Declarative Lookup Rollup Summaries Tool package (dlrs)
trigger dlrs_PeopleCloud1_Placement_Caa0fTrigger on PeopleCloud1__Placement_Candidate__c
(before delete, before insert, before update, after delete, after insert, after undelete, after update)
* Auto Generated and Deployed by the Declarative Lookup Rollup Summaries Tool package (dlrs)
private class dlrs_PeopleCloud1_Placement_Candia0fTest
private static testmethod void testTrigger()
// Force the dlrs_PeopleCloud1_Placement_Caa0fTrigger to be invoked, fails the test if org config or other Apex code prevents this.
August 20, 2015 at 7:45 pm
Sounds most odd, perhaps a bug. Can you post on the chatter group with screenshots and steps you do to reproduce. I am a little bus with Dreamforce prep right now, but hopefully others in the community can help. Chatter group link is on readme file. If your still struggling when I free up a bit i can take a look.
September 4, 2015 at 9:20 pm
I absolutely love this tool! Thank you!
Unfortunately, I just ran into my first issue. When trying to do a rollup from Campaign Member to Contact, I get the following error when I try to deploy the trigger:
dlrs_CampaignMemberTest.testTrigger System.DmlException: Insert failed. First exception on row 0; first error: MALFORMED_ID, Invalid campaign id: null: [CampaignId] (dlrs) Class.dlrs_CampaignMemberTest.testTrigger: line 11, column 1
Any ideas? Looks like it’s looking for a required Campaign ID in the test case and get getting it.
September 5, 2015 at 9:04 am
Thanks! Take a look at the GitHub issues list, this has been raised recently with a solution.
September 8, 2015 at 3:16 pm
Ah, perfect. Thanks @afawcett and @GregDevine!
September 23, 2015 at 5:27 am
I love this tool! I’m wondering if it is possible to do a query on ‘two quarters ago’, ‘three quarters ago’, etc. I currently am testing CALENDAR_QUARTER(Order_Date__c) = 3 AND Order_Date__c = THIS_YEAR which is nice but for dashboard purposes isn’t sustainable since we’ll still have to go in and change the date fields when the quarter changes.
Any help or documentation that might assist is much appreciated.
September 23, 2015 at 5:30 am
This should be possible, check the soql where clause docs and/or post in the chatter group (see readme on repo for link), I am in the U.S. at the mo with little free personal time, so chatter group will tap into further folks supporting this tool in the community
September 23, 2015 at 5:46 am
Thanks! I posted it out there.
September 29, 2015 at 1:17 pm
Is there anything in the Concatenate Delimiter field that I can enter that will not just put the values on different lines but put a space in between each value? E.g. I am using BR() which gives me
However it would be great if it could be displayed as:
October 8, 2015 at 4:14 pm
This is a great tool! I am having issues viewing the fields in sharing criteria or referencing it in formula fields. I have permission to view the field, any help would be appreciated!
October 8, 2015 at 4:47 pm
Please disregard my previous comment, it was my mistake.
October 8, 2015 at 4:56 pm
Ok, glad you sorted it!
October 20, 2015 at 9:26 pm
@Andrew Fawcett we currently face issue 61: https://github.com/afawcett/declarative-lookup-rollup-summaries/issues/61
We are updating cases via Bulk API. From the Case there’s a Rollup to Contact. The update fails with the UNABLE_TO_LOCK_ROW error.
Have you figured out any better solution how to avoid this in the meantime? I think running in scheduled mode will also not help in all cases.
October 20, 2015 at 9:27 pm
Do you have parrallel mode enabled for bulki API?
October 20, 2015 at 9:58 pm
Data is loaded via Jitterbit in packages with 200 records in one batch (as far as I know – I have no access to the Jitterbit update machine).
October 20, 2015 at 10:06 pm
There maybe a setting to control parallel, have a look round the settings if you can
October 20, 2015 at 10:21 pm
Ok, how would you set up the setting for parallel? Anything I should consider?
October 27, 2015 at 4:46 pm
Declarative roll-ups are GREAT…I have an interesting use case in which my child object is an event to which I am aggregating information to the relationship field WhoID (Lead object)
Events do not require the user to “complete” the activity…being completed is Now () > ActivityDateTime….I have created a formula field called IsActivityComplete that uses the above formula (the built in IsClosed is not available for Events, just Tasks)….anyway IsActivityComplete is part of the Relationship Criteria….of course, when an event automatically completes due to passing the End Date of the event (ActivityDateTime)….the rollup summary trigger does not fire.
Now clicking on the Calculate button will force a new calculation and all is good. So, I thought I would create a “scheduled” job via the calculation mode feature you implemented. Come to find out that this is actually keeping track of records to update based upon the same criteria that would have fired the real-time trigger….as opposed to scheduling a FULL Calculate….So, this does not do what I wanted…
Am I missing something or can I schedule a FULL Calculate nightly to pick up on events that complete due to time and not a user event (edit, delete, etc.) on the Event object.
Thanks so much
October 28, 2015 at 9:03 pm
No your not missing anything, as per the limitations on the readme file, formulas are tricky to use as criteria. There is a workaround with workflow field updates to force an update of a real (shadow) field from the formula that should workaround this.
December 1, 2015 at 12:21 pm
Hi – Maybe I am not following – is this documentation for an add-on product and not out-of-the-box SalesForce? I am not sure – I came across this doing a web search. I cannot find this functionality anywhere.
What I need to do – I have a one-to-many relationship between Contact and a custom object (Appointments). I want to put the fields for only the latest Appointment on to the Contact record (so we can sync these fields with SilverPop). It looks like the functionality being discussed here may work. Please advise. Thanks.
December 1, 2015 at 12:54 pm
Yes indeed it sounds like your use case is a good fit. To clarify this is a community lead peace of open source software. It is available in direct source code form or most commonly installed via the packaged install link route into your salesforce org. The install link and other related docs and videos are linked from the README file in the GitHub (placed used to share code) repository, which is linked from this blog. Finally linked via the README file is very active Salesforce Community Group, where you can interact with other users and knowledge experts. That should get you going, if not please ping me back or the Chatter group. 🙂
December 1, 2015 at 1:05 pm
You should also checkout a recent blog talking about using DLRS to implement “Lookdown Lookups”, sounds exactly like the approach you need.
December 17, 2015 at 12:22 am
This is fantastic! Such a huge product gap, and to be able to use this tool is a huge productivity booster.
Am I correct that you can’t filter on multiple criteria? e.g. OwnerId = ‘00550000001jQ3U’ AND Type LIKE ‘%Meeting%’ for example?
December 17, 2015 at 12:26 am
Thanks. And sure you can use multiple criteria. You have to know some soql syntax currently though. Give it a try and if you hit issues try posting in the chatter group (link in the read me file), either a community member or myself can help further. Enjoy!
December 17, 2015 at 1:36 am
Thanks, Andy! I was using Workbench to structure it, but maybe I was running into some other error.
Do you happen to know if there’s any way to reference “ALL ROWS” in the relationship criteria? Just ran into an issue with counting the number of tasks and realized that Salesforce archives older activities (more details below). No worries if it’s a limitation of the system – we always want to push it just a little further. 🙂
Salesforce.com archives older activities according to the conditions below:
• Events with a due date greater than 365 days old
• Closed tasks with a due date greater than 365 days old
• Closed tasks without a due date that were created more than 365 days ago
Someone in the above thread suggested adding “WHERE IsDeleted = false LIMIT 1000 ALL ROWS ” to a query to solve the issue.
And I’ll definitely keep the Chatter group bookmarked! Thanks!
December 17, 2015 at 8:50 am
Hmmm add ALL ROWS on the end might just work actually, give it a go and let us know.
December 17, 2015 at 5:54 pm
Hmm.. ALL ROWS didn’t do it, but I did manage to use multiple criteria. I’ll post the ALL ROWS issue to the Chatter group!
December 28, 2015 at 7:17 pm
Hi Andy, I love the new updates and excited to use try out the new features. I am getting the following after upgrading to v2.0-
Invalid field ‘CurrencyIsoCode’ for object ‘dlrs__LookupRollupSummary2__mdt’. Any ideas?
December 28, 2015 at 9:46 pm
Yes, this was reported a couple of hours ago, on my way home to fix it now. Keep an eye out in the next few hours.
December 28, 2015 at 11:53 pm
Just released v2.1 to resolve this.
December 29, 2015 at 11:18 am
December 30, 2015 at 10:36 pm
Can this tool be used for master/detail relationships as well?
December 31, 2015 at 10:01 am
In theory yes, though why would you over standard platform features?
December 31, 2015 at 11:31 pm
Seems like you’ve gone well beyond the standard features. As far as I know the standard feature doesn’t have text rollups. Is there something I’m missing?
December 31, 2015 at 11:44 pm
That’s correct, that would be one reason.
February 17, 2016 at 6:55 am
This is a very helpful tool. However, I came across a strange and bothering issue – let’s say I have a junction object and I have a roll-up on one of the parent objects concatenating the other parent object’s IDs. If I delete one of the concatenated Parent objects my roll-up field is not updated (meaning the ID remains). Is this a known issue? Does anyone know of a workaround?
February 24, 2016 at 7:54 pm
I think I would have to see the rollups and a schema diagram (schema builder screenshot) of the objects. Can you maybe post on the Chatter group linked in the README. See if I can help!
February 25, 2016 at 7:38 am
Hi, I actually posted since on the chatter group, I have the same case described in a know issue (https://github.com/afawcett/declarative-lookup-rollup-summaries/issues/257) so I am looking forward to see if there is a solution for this 🙂
Thanks for the reply!
March 2, 2016 at 2:02 pm
Hi! Where do I find the link to actually download this app?? I think a client of mine would really benefit but I can’t seem to find it in the app exchange 😐
March 2, 2016 at 3:31 pm
There are package install links in the readme file with the repository linked in this blog that the tool resides in
April 6, 2016 at 11:14 am
Hello Andy. I am a User of Roll Up summaries. I think it is great and have used it to enhance reporting without need to change data structures etc. I am trying to schedule my roll ups to run once a day. However I cannot seem to find the “Schedule” button to add to the page layout. What am I doing wrong?
April 6, 2016 at 1:25 pm
Your most welcome. You need to schedule via the Setup and Apex Classes page. There is some notes in one of the blogs linked to the Readme in the repo. Let me know if you still cannot find it.
April 6, 2016 at 8:51 pm
Hi Andy. I want to do exactly what Richard is asking about. You wrote “You need to schedule via the Setup and Apex Classes page. There is some notes in one of the blogs linked to the Readme in the repo”. I looked for the notes on this but couldn’t quite find them. Could you post a link or point me in the right direction?
April 8, 2016 at 10:05 pm
Sure here you go, https://andyinthecloud.com/2014/02/09/new-release-spring14-declarative-rollup-summary-tool/
April 19, 2016 at 8:17 pm
Hi Andy, we’ve been using the declarative lookup roll-up summaries for a couple years. How do I determine what release we are on and what’s the latest release available? Also, all of roll-ups are set to run “real-time”, but a couple don’t. Do you know what could be causing this? Sorry for the basic questions. I’m not very technical and am new to being the administrator of the app in our organization.
April 19, 2016 at 8:41 pm
Go to Installed Packages under Setup. Latest version is on the GitHub readme file.
April 19, 2016 at 8:41 pm
Couple don’t do what? Run you mean?
April 19, 2016 at 8:43 pm
Thanks for the quick response. They don’t run real-time all the time. I have to manually click the “calculate” button even they they are setup to run real-time.
April 19, 2016 at 8:44 pm
Are you rolling up formula fields?
April 19, 2016 at 8:48 pm
Yes. Also, we are on version 1.9.
April 19, 2016 at 9:37 pm
Check the readme for the tool, there is a list of blogs, the last one I did speaks about formula field rollups, they have special considerations, you need to let the tool know more info on the fields to monitor from your formula, otherwise it won’t spot changes and do the calc, suspect that’s what your issue is here
April 20, 2016 at 2:21 pm
Thanks! I will look into this.
May 10, 2016 at 2:19 am
I’ve been using the tool for a few months now. I just went to add a new rule and see message “Unable to connect to the Salesforce Metadata API.” I upgraded to 2.3, then deleted dlrs_mdapi and click “Create Remote Setting”. It seems to have been created properly. But when I go to Manage Rollups I’m still getting error “Error:
Salesforce Metadata API connection failure, click the link below to configure.”
I’ve done this process a couple times and keep getting error.
Any idea what I might be missing?
May 11, 2016 at 12:12 am
Have you got some session policies setup? Check out the readme file I put some details on this possible reason in that.
June 23, 2016 at 11:27 am
Hi Andy, I am having an issue with some other automation in my system that runs on insert of records. I am getting an error that appears to be caused by a duplicate value for the Qualified Parent ID on the Lookup Rollup Summary Schedule Item object, which is a unique field. I was wondering if you have ever seen this before and if you could explain to me how the Lookup Rollup Summary Schedule Item records are created and why they may be getting created multiple times for one parent record?
June 25, 2016 at 7:56 am
This sounds like a bug or some kind of concurrency issue, as you say it should be only one per parent record that needs recalculating. Is your automation system running parallel inserts? Also can we continue discussion via a GitHub issue on the repo if thats ok?