Andy in the Cloud

From BBC Basic to Force.com and beyond…

Declarative Rollup Tool Summer Release!

119 Comments

Over the course of the last couple of weeks, i have been focusing my community time on release v2.4 of the DLRS tool. Specifically focusing on some much requested features driven by the community in the the Chatter group.

So lets get stuck in…

Rollup Scheduler Improvements

The ability to run a full (or partial with criteria) recalculate of a rollup on a daily schedule has been in the tool for a few releases now. However up until now the only option was to run it at 2am everyday. It is now possible to change this with this new UI, its a bit raw and basic, but for now it should at least give some more flexibility.

RollupSchedule.png

Support for Merging Accounts, Contacts and Leads

The platform has some special handling for merging Accounts, Contacts and Leads. Especially when it comes to when Apex Triggers are invoked. Basically if your parent object is one of these objects, prior versions of the tool had no awareness of this operation, so rollups would not recalculate. If you are using Realtime or Schedule calculation modes on your rollups. Since the platform does not fire Apex Triggers for child records reparented as a result of a merge.

With this release there are two things you can do to fix this. First when you click the Manage Child Trigger button, you get a new checkbox option to control deployment of an additional Apex Trigger on the parent object. If your upgrading you will need to click Remove then Deploy again, to see this.

ParentTrigger.png

IMPORTANT NOTE: If you don’t feel merge operations are an issue for your use cases you can deselect this option and cut down on the number of triggers deployed. Also if it is only the rollup child object that supports merging, there is no need to deploy any additional triggers and the tool does not show the above checkbox option.

Secondly you need to setup the RollupJob as an Apex Scheduled job (under Setup > Apex Classes), even if you don’t have any Schedule Mode rollups. This is due to the fact that due to a platform restriction, the tool cannot recalculate rollups realtime during a merge operation. So it can only record that they need to be recalculated. It does this via the tools scheduled mode infrastructure, by automatically adding records to the Lookup Rollup Summary Schedule Items object. Note that you don’t need to change your rollups from Realtime to Scheduled mode for this to work, only schedule the job.

Support for Archived / Deleted Records via the All Rows Setting

Salesforce archives Tasks and Events after a while. If you have rollups over these child objects you can enable the Aggregate All Rows checkbox. This will ensure your rollups remain accurate even if some records have been archived. Note this also will apply to records in the recycle bin. For upgrades (if your not using the Manage Lookup Rollup Summaries tab), you will need to add this field to your layout to see it.

AllRows.png

Row Limit for Concatenate and Last Rollup Operations

If your using the Last or Concatenate operations, you can define a limit as to how many child records are actually considered when calculating the rollup. This is useful if your using Concatenate into a fix length field for example. When upgrading you need to add the new Row Limit field to your layout if your not using the swanky new Manage Lookup Rollup Summaries tab.

RowLimit.png

Improved House Keeping for Scheduled Mode

If your are using rollups with their Calculation Mode set to Scheduled. The tool records parent rollup records to be later recalculated by the RollupJob Apex Scheduled job. In past releases if through merge or other operation the parent record was deleted before the next scheduled run. Then records would sit in limbo in the Lookup Rollup Summary Schedule Items object, being processed and erroring over and over. These will now be cleared out and there is no upgrade actions you need to take for this.

Summary

Thanks for everyones support for this tool, i hope these changes help you go further with clicks not code! Though as reminder please keep in mind the best practices and restrictions listed in the README. If you have any questions you can either post comments on this blog or use the Chatter Group. The Chatter Group is a great place to get your query seen by a broader group of people who are also diligently supporting the tool as well!

You can find releases of the tool here.

119 thoughts on “Declarative Rollup Tool Summer Release!

  1. Andy, thanks so much for this truly wonderful tool. It has solved so many problems in an extremely complex SF environment, I praise your name each time it saves the day! These new additions will help even more. If you are ever in Berlin, please look me up. You have quite a few fans here in our SF developer group!

    • Thanks for your kind words! I will for sure keep your offer in mind. In the meantime please say Hi to the group from me! 🙂

  2. Hear! Hear! I agree with Alexis! Thank you, Andy

  3. Hi Andy! Love your app. On Github, the sandbox install link for 2.42 is actually the same as the production install (http://login.salesforce… instead of http://test.salesforce..)

  4. Hi Andrew, congrats for the tool. It´s really a great help you are doing to the community. I´m just starting to create by Rollups and would like to know if it´s possible to identify the last value in a child object. It´s possible to get the last date using the MIN and also the lowest value also with MIN but my need is to get in a custom object not the lowest value, but the last. In my context I want to find out the last price I sold a product.

    Do you think it´s possible.

    Thanks again.

    Antonio

  5. How can I get events count without invitees?
    I got count with invitees.

    • I am not sure of the object model from memory and not near my computer to check. But I wonder if it’s a case of doing two rollups? Also you may get more traction through posting on the Chatter group linked on the README file

  6. Andy,

    I’m trying to uninstall this and it’s impossible. It keeps saying there are 4 classes that it can’t remove and I’ve tried everything and cant remove them. Any help is greatly appreciated.

    Brandon

    • You need to use the Manage Child Trigger button on your rollups and click Remove to remove these classes.

      • I removed the package. No error after install, but the package still there on Production and a schedule job is presenting this king of message: caused by: dlrs.RollupServiceException: Invalid rollup m002T000000XZDVQA4 not found.

        Class.dlrs.RollupService.runJobToCalculate: line 93, column 1
        Class.dlrs.RollupCalculateJobSchedulable.execute: line 11, column 1

        Is necessary open a ticket on Salesforce support to uninstall the package or is there a way to remove the package forever? Too many collateral errors with others programmatic code using your product on the client org where it was installed by previous consulting company.

      • Not sure how you manged to uninstall and still have a Scheduled job still present? That’s confusing to me. Make sure to go to packages under setup. You May need to go to rollups and click Managed Child Trigger to undeploy the Triggers frost and also go to Scheduled Jobs under Setup and delete those as well.

      • Dear Andrew, thank you for your reply. I did that. I removed all child triggers. Click on Uninstall, no error, but the package still there. No active schedule jobs. After uninstall, the botton on the left of package name disappears, but after a browser refresh it come back again.

      • That sounds most strange. I don’t really have any ideas. It sounds like you are doing things correctly to me. Perhaps raise a support ticket with salesforce?

      • OK, thank you one more time. I’ll open a ticket.

  7. Hi. For the newer metadata functionality”Manage Lookup Rollup Summaries”, is there a way to clone an entry like there was for the older “Lookup Rollup Summaries” tab? Just wondering. It would help a lot as I have several rollups I need to do from the same object, but for now I am just doing manual entry.

  8. Hello Andy. Thanks for your answer to my previous question – that worked fine.

    I have a bit of a strange use case where I might need certain rollups on the same object to execute in a specified order (long story…). I just wanted to know if I have several rollups on the same object is there any particular order they will be executed in (like alphabetical based on name, etc.)? Or is that non-deterministic? I am just trying to weigh certain options to possibly solve a problem that there might be no solution for in any case. Thanks.

  9. Hi Andy, thank you for this amazing tool! I wish I have found this earlier.

    Thought maybe you or community here will have any ideas on the problem I am trying to solve. We need to calculate how long does it take a rep to get back to a lead after website form submission.

    I did it partially:

    1. Logged first call date/time (using Last operation) on Lead Object

    2. Created a formula field that calculates time to get back in minutes (Date_time_of_first_call__c – Form_Submission_Date)*24*60 – First_Call_Duration__c

    CHALLENGE:

    A lead submits a form today => Rep calls => Time to get back to lead gets calculated => 3 months later same lead submits another form :-/

    Date time of the first call will be outdated and time to get back will be set to 3 month which will cause inaccurate data.

    Any help or ideas would be highly appreciated!

    Thanks a lot in advance,

    Kate

    • I am afraid I have read this a few times, I am not clear on what a form is or how it affects your object model. It’s worth posting on the Chatter group, maybe with screenshots and/or diagram of your object model. The link to the group is on the readme file. Thanks

  10. You are a true Salesforce Hero. Thank you

  11. Hi Andy,
    I have had some MVPs point me to your tool. I’m very excited to try it out.
    I just tried installing it in my sandbox from the appexchange, but received a message that it had been deprecated and couldn’t be installed. I was wondering if it will be available to install soon…or maybe I just bypass that and add it to production.

    Thanks for your time!

    best,
    Julie

    • Great, hope it works out for you. Sounds like you have an old link. Got to the readme file and there is a releases section. Install the latest v2.5 link. Thanks

  12. Pingback: Declarative Rollup Tool Summer Release! — Andy in the Cloud | SutoCom Solutions

  13. Hi Andy,

    I am working in Salesforce Professional edition environment and I need this app to install there badly. I know this is not support to Professional Edition, but somehow, is there a way to make it work?

  14. Andy, maybe you can help me. We recently started receiving errors like this after merging Contact records, and it is coming from one of the DLRS triggers:
    Apex trigger dlrs_ContactTrigger caused an unexpected exception, contact your administrator: dlrs_ContactTrigger: execution of AfterDelete caused by: System.NullPointerException: Attempt to de-reference a null object: (dlrs)
    Is there any way to work around this? It looks like it is referring to a contact that was deleted because of the merge. Thanks.

  15. Hi Andy!

    What API Version is this tool for? I would love to roll up related contacts via AccountContactRelation, but that is available in 37.0 and I get an error when I try to use it as the child.

    Can you please help me?

    Thank you,

    Kelly

  16. Hi Andrew, is the latest version compliant with Salesforce TLS1.0 disablement? Thank you very much.

  17. Absolutely love this tool. however i’m experiencing an issue. i have 2 rollup summary jobs that are summing values based on an account to account lookup. 1 of the jobs is for customer record types and the other job is for partner record types. in each rollup i’m using the same field to aggregate to on the account but i’m applying a filter criteria in the where of each job checking for the specific lookup relationship to have a value. so for customers lets say its “Parent_Account__c null” but for the Partner job its “Partner_Account__c null”. my thought here is that the Parent Customer job will not touch or aggregate the field on the Partner Parent record and on the Partner Job it will not touch or aggregate the field on the Parent Customer record.

    What I am seeing is the contrary. When I calculate the customer job I see the field with the right value on the Parent Customer record. Then when i go and calculate the Partner parent job it overwrites the Parent Customer ones back to 0 even though the child accounts don’t have a Parent Customer lookup value populated (they only have a Partner Parent lookup field populated).

    • Yes this is currently by design, in order to avoid this you need to use the filter criteria on the Calculate or Schedule Calculate page, without this it processes each parent. The criteria on the rollup is only used when doing realtime calcs or Calculation Mode = Scheduled

      • ahhh perfect. that works i misunderstood how the calculate button worked and that it was to filter on the parent. thank you andy and thank you again for such a fantastic tool!

    • MattB, I’m new to the DLRS and am trying to use a RecordType as a Relationship Criteria and am getting the error that the RecordType doesn’t exist on the object (which it does). Would you mind giving me an example of your Relationship Criteria that uses RecordType?

      • I think it’s RecordTypeId

      • Thanks for your quick response. I’ve run into another issue and it looks like we may need to add some fields to work on a rollup within the same object. We are looking to create 4 levels of hierarchy in a custom object:

        Metro
        – Market
        – Community
        – Neighborhood

        There is one “parent” field that is used to create the hierarchy (Neighborhood’s parent is Community whose parent is Market whose parent is Metro)

        It appears that this passes a limit of DLRS as the Rolledup Value is zeroed out at the Community level when I activate the Market DLRS. It seems that we’ll need to use separate fields at the Market and Metro level. Does that sound right? Thanks in advance.

      • Yes you need to use separate fields. You can add them back together using formulas though

  18. Hi Andy, I just want to say that this tool is AMAZING!

    One issue that I have, though, is that when I deployed it in my org, it installed the latest version of the tool, but it is still writing triggers in 32.0. I need to access an object that is not available until 37.0; is there a way that I can write triggers in 37.0? Conversely, when I updated this tool in my Dev org, it did write in 37.0. Am I doing something wrong in production?

    Thank you!!!

  19. Hi all,
    I’m experiencing the following error from the RollupService triggerHandler: “first error: UNABLE_TO_LOCK_ROW, unable to obtain exclusive access to this record”. I suppose do to a realtime trigger event to update a parent account and I have a nightly integration bulk job performing upserts. Any advice how to overcome this? In this article they call for adding FOR Update in the SOQL but since this is a managed package we cannot: http://salesforce.stackexchange.com/questions/20921/can-anybody-explain-the-unable-to-lock-row-error.

    • any way around this that anyone knows of?

    • If could be that your child records are being inserted in parrellel under high concurrency. Are you using a data loader? If so you may have to disable parallel mode or switch to the schedule mode (see GitHub repo page and link in wiki on this) or temp disable via setting active to false on rollup records, then do your data load, then reactive and press Calculate to catch-up the roll ups

  20. Andy, If I want a job to just run on the 2nd of the month do I set the Execution Mode to like Developer and then use the Scheduled Calculate button to set the schedule?

    • Use Calculation Mode = Process Builder (I know not that obvious since your not using), then use the Schedule Calculate button and specify your schedule

  21. Andy,
    Like everyone else I love the tool. Saved my life a couple of times. I dont know how to write the relationship criteria to count cases that have been open longer than 2 weeks. I have everything set except that one formula. Can someone help me with that?

    • Thanks glad you appreciate it. I am just getting in on a flight so hard to try out for you. Take a look at this sort of idea https://developer.salesforce.com/forums/?id=906F0000000kBWeIAM. You will have to use Schedule Calculate function though as trigger mode will not work as it cannot detect the passage of time to recalc the values. Set the Calculatioj Mode to Processs Builder (even though you won’t use it from that). You can test with the Calculate button to run a full Calculate job on demand. If your still getting issues, this is just the sort of thing the Chatter group helps with (see link in the readme file).

  22. Hi Andrew, I have said I love your tool and I’ll say it again. I use it in 80% of my praojects!

    I am new to Apex but have written a Declarative Scheduling tool. It allows you set up regular schedules that will update records. An admin can then set up a process build to fire whenever the schedule is triggered.

    You can now have tasks generated for all open opporuntiities with the close date in the past and no activity in the last 14 days. Any logic you can add to a report.

    I have deisgned it to be sObject generic. It also can run up to 60,000 records at the moment (which is overkill.

    First draft. I would love any input into how it could be made better. I also think so of the declarative admins out there might find this really useful

    https://github.com/dthowell/DeclarativeScheduler

    • Hey sorry I totally missed this! Fine work my friend! I would recommend to make it easier for people to try out you create a manged package and publish it on your readme. You can encourage developers to contribute more by adding the Deploy To Salesforce button on your readme. Also people who just want the code in their sandbox can use this way if they want. Great work, love how you used an existing platform feature to drive the criteria.

  23. Hi Andrew – i was hoping to email you privately but I am not finding your contact info.
    We have a client that has to adhere to HIPA requirements. I would like to ask for your help please?

    I would like to just confirm if any process or tools in this app require that data leave the client instance and/or there are any other actions that might be HIPA compliancy issues? If data does leave client instance for a process, how is that data managed?
    Also i was not finding your app in the SF Appexchange – was it always only available here?

    thank you in advance for your quick feedback!

    • I am not a HIPA expert but can confirm it runs solely on Force.com and does not use any external services for calculating the roll ups. To configure the tool, it does call out to an Salesforce SOAP API know as Metadata API, however no data is exchanged. The package is not on AppExchange, but has gone through the security review process (see Readme file) and is available as a managed package for ease of install, management and upgrade.

  24. When merging account records, is my understanding correct in that the rollups will only run whenever the RollupJob is scheduled to run?

  25. Hi Andrew,
    JI already use the application but I have a question. Could you send me an email?
    Thank you

  26. Hi Andrew, I am trying to find and install declarative rollup helper in a sandbox and I can’t find a link to do so. Can you point me in the direction of its location?
    Thank you,
    Kathy

  27. I have received this error after creating a rollup for calls:

    Apex script unhandled trigger exception by user/organization: 005D0000009Cw8n/00DD0000000mBBO

    dlrs_TaskTrigger: execution of AfterInsert

    caused by: System.SObjectException: Invalid field Who for Task

    (dlrs)

    Parent Object: Lead
    Child Object: Task
    Relationship Field: Who
    Relationship criteria: Type IN (‘Call Attempt’, ‘Call Connect’, ‘Call’) AND (Status = ‘Completed’) AND ((CreatedDate = LAST_N_MONTHS:12) OR (CreatedDate = THIS_MONTH))

    What am I doing wrong?

    Thank you very much.

    • Also when a user now tries to log a call in salesforce they receive the following error:

      Error: Invalid Data.
      Review all error messages below to correct your data.
      Apex trigger dlrs_TaskTrigger caused an unexpected exception, contact your administrator: dlrs_TaskTrigger: execution of AfterInsert caused by: System.SObjectException: Invalid field Who for Task: (dlrs)

      • See my response on your other post to try WhoId. In the meantime you can disable your roll up be unticking the Active field

    • Try WhoId

  28. Andy, Thanks for this app – I’m getting a “2.3 has been deprecated” message on the appexchange and am unable to find v2.4. Will you let me know where we can get it for install? Thanks.

    • Go to the readme file and the latest install link can be found. Thanks!

    • Hi Andy,

      I am getting an error when I try to uninstall the tool in one of our SFDCs:

      Error
      Unable to uninstall package
      Problems

      Component Type Name Problem
      Apex Class RollupService Component is in use by another component in your organization. dlrs_LeadTrigger
      Apex Class RollupService Component is in use by another component in your organization. dlrs_LeadTest
      Apex Class RollupService Component is in use by another component in your organization. dlrs_TaskTrigger
      Apex Class RollupService Component is in use by another component in your organization. dlrs_TaskTest

      I am not able to figure out what is blocking it 😦

      • Please check the README file for the latest package install link. Thanks!

      • Sorry, Andy! I weren’t able to find anything on this in the read me file. Would you please refer me to some documentation on how to fix that?

        Thank you for the great tool!

        Kate

      • I still don’t see any info on install issue :
        Name Problem
        Apex Class RollupService Component is in use by another component in your organization. dlrs_LeadTrigger
        Apex Class RollupService Component is in use by another component in your organization. dlrs_LeadTest
        Apex Class RollupService Component is in use by another component in your organization. dlrs_TaskTrigger
        Apex Class RollupService Component is in use by another component in your organization. dlrs_TaskTest

        It started to give error message email last week:
        Apex script unhandled trigger exception by user/organization: 00550000005heIL/00D50000000BKS9

        dlrs_LeadTrigger: execution of AfterUpdate

        caused by: System.NoAccessException: Entity is not api accessible

        Class.dlrs.fflib_SObjectSelector: line 36, column 1
        Class.dlrs.RollupSummariesSelector.CustomObjectSelector.: line 102, column 1
        Class.dlrs.RollupSummariesSelector.: line 43, column 1
        Class.dlrs.RollupService.describeRollups: line 990, column 1
        Class.dlrs.RollupService.handleRollups: line 673, column 1
        Class.dlrs.RollupService.triggerHandler: line 307, column 1
        Trigger.dlrs_LeadTrigger: line 7, column 1

  29. Hi Andy,

    Getting this error from package version 2.8 installed on 3/29/2017. Facing error only from community user, works fine for other users.

    Update failed. First exception on row 0 with id a0SJ0000007g1oYMAQ; first error: CANNOT_INSERT_UPDATE_ACTIVATE_ENTITY, dlrs_GW_Volunteers_Volunteer_Ha0STrigger: execution of AfterUpdate caused by: System.DmlException: Insert failed.
    First exception on row 0; first error: DUPLICATE_VALUE, duplicate value found: dlrs__UniqueName__c duplicates value on record with id: a1PJ00000019VbM: [] Class.dlrs.RollupService.updateMasterRollupsTrigger: line 949, column 1 Class.dlrs.RollupService.handleRollups: line 829, column 1 Class.dlrs.RollupService.triggerHandler: line 302, column 1 Trigger.dlrs_GW_Volunteers_Volunteer_Ha0STrigger: line 7, column 1: []

    Any idea?

  30. Hi Andy,

    This tool has been a lifesaver on so many different occasions! A big, big thanks for creating this!

    I’m having problems when the parent object is the User object though. Is this not supported by the tool? When the user is the parent object the apex job only shows 2 batches even if I have a lot of records to roll up. Doesn’t matter what the child object is, or whether there are relationship criteria, it’ll always show 2 batches being processed.

    Thanks!

  31. Hi Andy,

    I have deleted Lookup Rollup Summary without clicking the ‘manager child trigger’ button and then remove.
    What I did is to inactivate it and then delete it.
    But I think its still working and causing me a lot of issues in the system.

    How can I fix it now?

    Thanks!

    • Even if the dlrs triggers are still deployed, if there is no rollup records in the system the trigger will do nothing.

  32. Andrew I’ve always used simple roll ups for DLRS (no filtering) but have a use case where I need to add a Relationship Criteria – do you have a link to an example on setting up the Relationship Criteria….my first pass at this is not working as expected…

  33. Hi Andy. I’m a huge fan of DLRS and have just installed it for another client. I was having difficulty finding the right object names and was all over the SOAP API documentation. I eventually found the right name and the DLRS worked flawlessly. Thanks again for developing this product. It has been a critical part of successful deployments at a number of my clients.

  34. Hi Andy,
    I love DLRS!
    I recently upgraded to the latest version and am having some trouble with a roll up summary. I’m trying to pull in the what record name into a custom lookup field I created if that what record is an opportunity. I have ‘Task’ as the parent object. ‘Opportunity’ is the child object. Relationship field is ‘ID’. Field to Aggregate is ‘Name’. Aggregate operation is ‘First’. Aggregate result field is ‘Opportunity_WhatID_Lookup__c’ which is the custom field I created to display the oppty name to be used in communication templates.

    When I create a task and related it to an opportunity, the custom field I created is still blank. Do you know what I’m doing wrong?

    Thanks in advance for your help!

  35. Hi Andy,
    I love the functionality that DLRS provides for us. I’m still rather new to the tool, and was wondering if you could tell me what dictates the batch size for the Apex Job when it runs? I have one Summary that runs in 4 batches, starts and completes within the same 60 seconds, and has been in place for several months. However I added a new Lookup Rollup Summary today that has much more narrow criteria, but it takes 47 batches and about 11 minutes to complete. Being as I want to utilize this tool more broadly across our organization, I want to create them in the most efficient way possible. Any ideas?

  36. Hi Andy,

    I have a contact with more than 50 thousand opportunity When I run the roll up I get the following error.

    First error: dlrs:Too many query rows: 50001 RollupCalculateJob

    Is there any work around to get this rolled up.

    • This is a known limitation, please review the README section on known issues and limits. However, if you have a single master record with more than 50k children there is no workaround for this platform limit i am afraid.

  37. Pingback: Why to keep finger on the pulse of the Ohana community? - Blog Martina Humpolce

  38. Hey Andy,

    DLRS has sorted so many of our problems now, I can’t thank you enough. I was wondering if I can create a rollup to count files on a Case or Work Order as well? For some reason I can’t seem to get the Relationship Criteria working.
    I’m creating –

    Criteria: LinkedEntityId LIKE ‘500%’
    Parent object: Case
    Child object: ContentDocumentLink
    Field to aggregate: ContentDocumentId

    Is there a way to get linked entity type and using that in criteria instead? For example, can I use LinkedEntity.Type ? I have tried writing relationship criteria in many different ways but it doesn’t work. I’m not sure if this is workable via DLRS?

    Thanks
    Anamika

  39. Hi Andy,

    in the Field to Aggregate is it possible to choose two or more fields so that these two fields are aggregated in to Aggregate Result Field

  40. Hi Andy, we have the managed package installed and are trying to create a rollup with some complex logic in the Relationship Criteria field. We’re hitting an error where the SOQL query is too long for the text area field. Obviously, the nature of the managed package prevents us from increasing the length of the field. Are there any workarounds or alternative solutions that we could use here?

    Thanks!

  41. Hi Andy,

    How does this package work in Lightning? It doesn’t have a Lightning Ready Sash and comes up on the Lightning Readiness Report as orange.

    Thanks!

  42. Hi Andy,

    How does this package work in Lightning? It doesn’t have a Lightning Ready Sash and comes up on the Lightning Readiness Report as orange.

    Thanks!

    • It works just fine. Most of what it does is not UI driven, thats just the config bit. Day-to-day its in the background. I am working on making a release that makes it fit better in Lightning but you can basically try it today as-is. If you hit issues, configure it as normal in Classic and rest assured the rollups will work in either UI or for that matter API interactions.

  43. Hi Andy…..

    Could you please help us solving an issue? We are using Salesforce NPSP and we have created a Rollup to count the Active Recurring Donations of a Contact. We receive an error deploying the Apex trigger. The error is:

    Error:
    dlrs_npe03_Recurring_DonationTest.testTrigger System.DmlException: Insert failed. First exception on row 0; first error: FIELD_CUSTOM_VALIDATION_EXCEPTION, You must select an Organization or Contact: [] Class.dlrs.RollupService.testHandler: line 282, column 1 Class.dlrs_npe03_Recurring_DonationTest.testTrigger: line 11, column 1

    What can we do to solve this issue?

    Hope you can help us. Thanks in advance!

  44. Hello Andrew Fawcett,
    We are experiencing some issues with DLRS due to last update of salesforce. Did someone report you? Do you have any e-mail to talk about?

    • Yes. Hopefully this will be fixed soon. Meanwhile checkout the issue on the GitHub issues list for this tool. It has an install link to a patch release I made a few days ago to workaround it meanwhile. Andy

  45. Hi Andy

    I’m having the same issue as posted by somebody above in 2017 – the problem only occurs in community and not in internal Salesforce. I don’t see a response to it there, hoping you can help us out.

    dlrs_Program_StudentTrigger: execution of AfterInsert caused by: System.DmlException: Insert failed. First exception on row 0; first error: DUPLICATE_VALUE, duplicate value found: dlrs__UniqueName__c duplicates value on record with id: a4S1M000000Xg8D: [] Class.dlrs.RollupService.updateMasterRollupsTrigger: line 1015, column 1 Class.dlrs.RollupService.handleRollups: line 922, column 1 Class.dlrs.RollupService.triggerHandler: line 311, column 1 Trigger.dlrs_Program_StudentTrigger: line 7, column 1

  46. Hello
    I have 4 rollup summary fields and i can see one is not working until i go and click recalculate (Real time option is selected) (Also system is selected) What could be the reason you think please advise
    Your time is much appreciated

    • Have you got the correct fields in the “relationship criteria fields” field? Also please let’s continue on the dlrs chatter community group (see link in the repos readme). Thank you! 👍🏻

  47. I have this error happening for many days now. The userId mentioned on the error does not even exist. If I tried to browse to the user Id record, it says insufficient privileges, and I am the admin.

    Apex script unhandled trigger exception by user/organization: 005F0000003yYpv/00DF000000065wX

    dlrs_AccountTrigger: execution of AfterUpdate

    caused by: dlrs.fflib_QueryFactory.InvalidFieldException: Invalid field ‘CreatedDate’ for object ‘dlrs__LookupRollupSummary__c’

    Class.dlrs.fflib_QueryFactory.getFieldPath: line 91, column 1
    Class.dlrs.fflib_QueryFactory.addOrdering: line 543, column 1
    Class.dlrs.fflib_SObjectSelector.configureQueryFactory: line 389, column 1
    Class.dlrs.fflib_SObjectSelector.newQueryFactory: line 273, column 1
    Class.dlrs.fflib_SObjectSelector.newQueryFactory: line 255, column 1
    Class.dlrs.RollupSummariesSelector.CustomObjectSelector: line 165, column 1
    Class.dlrs.RollupSummariesSelector: line 80, column 1
    Class.dlrs.RollupService: line 1069, column 1
    Class.dlrs.RollupService: line 750, column 1
    Class.dlrs.RollupService.triggerHandler: line 329, column 1
    Trigger.dlrs_AccountTrigger: line 7, column 1

    What’s causing this and how do I fix it?

    • Hi there is an active discussion on the github issue for this problem. Can you join that and share your story. We are trying to track down the cause and need more intel. Thank you! 👍🏻

  48. Hi Andrew – Have we found a solution for this problem? I am havingit too – ont he Account object. I am not a github users- don’t know how to join that conversation. Can you send me a link?

  49. Hi Andrew – We have multiple rollup fields that calculate aggregate field values from the Case object to the Account object and from Entitlement to the account object.

    It calculates based on a few criteria and the result is showing incorrect numbers. These are important fields for my Knowledge Center team. I have tried the criteria with different combinations but still couldn’t make the aggregate fields work correctly.

    Can a support person be able to help us with this issue? Thanks Much!

    • Sorry you are having an issue. This however is a community driven tool – not commercial. While this has its upsides – no sla is offered like a paid product. That said – there is an excellent community chatter group – where you can share your screenshots of your rule definitions and steps. Checked out the link to that on the readme file in the GitHub repo for the tool.

    • I would also try deactivating one and see if the other works. Note that the result field needs to be a different field in both cases

Leave a Reply to Andrew Fawcett Cancel reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s