Skip to main content
Content Starts Here
This is a publicly shared Knowledge Article from the Power of Us Hub - an online community for nonprofit and higher ed Salesforce users. Join the Hub.
Product Documentation

Create Customizable Rollups

Create a Customizable Rollup

You can create as many Customizable Rollups as you need. Keep in mind that you can also edit the out-of-box NPSP rollups and any other User Defined Rollups previously created in your org.

For example, say you want to know the the total amount of in-kind gifts that a Contact has donated. With Customizable Rollups, you can easily find that information and put it in a custom field called Total In Kind Gifts. We'll illustrate how to create this sample aggregate rollup in the instructions below.

Important

Customizable Rollups roll up data to a custom field (that you choose during the creation process). But that field must exist, so be sure to create the custom field before creating a new rollup! We recommend that you make these custom fields read only for all users (including Sys Admins). For more information, see A note about creating custom fields for use in Customizable Rollups . . .

This example we walk through in the steps below assumes that you have an existing custom field on Contacts called “Total In Kind Gifts.” If you want to follow along, you'll need to create that custom field first.

  1. Go to the NPSP Settings tab. If you don't see the tab in your org, you can find it from the App Launcher.
  2. Click Donations | Customizable Rollups.
  3. Click Configure Customizable Rollups.
    Note
    If you need to go back to a previous screen while using Customizable Rollups, use the breadcrumbs at the top of the page. The back button will not work; it will always take you back to the NPSP Settings page.
    Customizable Rollups page showing the breadcrumbs to go back to the Customizable Rollups list
  4. On the Customizable Rollups page, click New Rollup. To edit an existing rollup, in the appropriate row, click the drop-down arrow and then click Edit.
  5. Choose the Target Object and Field that the data should roll up to. The Target Object can be Account, Contact, General Allocation Unit, or Recurring Donation. The Target Field is limited to custom, writeable fields on the Target Object that aren't currently used by another rollup.
    Note
    Be careful if your Target Field can only accept certain values, for example, if the target field has validation rules or is a restricted picklist. If your source value is not accepted in the Target object, you will get an error when the nightly batch job runs.
    Important
    When creating a Recurring Donation rollup, ONLY use your own custom fields as the Target field. Selecting an NPSP field as the Target field will break your Recurring Donations.
    To create our example rollup, choose Contact as the Target Object and Total In Kind Gifts as the Target Field.
    Note
    Remember, this is just an example and it assumes that this custom field already exists. If you want to follow along, you'll need to create the Total In Kind Gifts field.
  6. Enter a detailed description of this rollup. This is very important because the description is what you (and others) will use to distinguish this rollup from all of your other rollups. For the example, enter "Sums up a Contact's total In Kind Gifts from the Opportunity Fair Market Value field."
  7. Enter the Operation. Your choices are limited based on the Type of the Target field you selected. For the example, choose Sum.
    The type of Operation you choose determines whether your rollup will be an aggregate rollup or a single result operation rollup. If you want to create an aggregate rollup, you'd choose Sum, Average, or Count. If you want to create a single result operation rollup, you'd choose First, Last, Largest, Smallest, Best Year, Best Year Total, Years Donated or Donor Streak.
    Note
    When you choose First or Last as the Operation, the First or Last record is determined based on the Date Field in the Advanced Customizations section. You can choose any of the available Date Fields listed in the drop-down. If there is more than one record that matches the criteria based on the selected Date Field, we use the Created Date as a tie-breaker to determine which record to use.
  8. Choose the Timeframe for this rollup. For the example, choose All Time.
    1. To roll up data for all time, choose All Time.
    2. To roll up data for a certain number of days back, choose Days Back. You will then see a Days Back field where you can enter the number of days back (from today) that you want to roll up data for. It's important to note that entering a value of 0 will roll up data for today, while entering a value of 1 will roll up data for today and yesterday. The maximum number of days back you can enter is 10000.
    3. To roll up data for a specific year, choose Years Ago. You will then see a Years Ago field where you can choose the number of years ago that you want to roll up data for. Keep in mind that only the data for that calendar (or fiscal) year will roll up. So, if the current year is 2018 and you choose 2 years ago, the roll up will include data for 2016. Select the Fiscal Year checkbox to calculate rollups based on fiscal year settings (instead of calendar year). 20 is the maximum amount of years ago you can select.
  9. Choose the Rollup Type. The Rollup Type is a combination of the object to roll up along with whether it will be a soft credit or hard credit rollup. For the example, choose Opportunity > Contact (Hard Credit).
  10. Choose the filter group to apply to this rollup. The filter group is a collection of filter rules that determine what records get rolled up. If you want to include all records, use the default No Filter Group (Include All Records). For the example, choose Opp: Won (HC).
    Note
    You'll see all available filter groups that exist in your org, but be sure to select one that uses the same object that you selected in the Rollup Type field.
  11. In the Advanced Customizations section, enter the required information. The fields that appear are determined by the Operation you selected.
    1. Field to Roll Up: Choose the field from the result of the rollup operation that you want to copy to the Target Field. This field is available if the Rollup Type is a single result operation (First, Last, Largest, or Smallest). Additionally, only fields with field types that are compatible with the selected Target field appear in the list.
    2. Date Field: Choose the date field to use when calculating the rollup. The Timeframe depends on this field.
    3. Amount Field: Choose the amount field to use when calculating the rollup. For the example, choose Opportunity: Fair Market Value.
  12. Click Save. Your rollup will look something like this:
    A new customizable rollup for total in kind gifts
    Note
    If you get a timeout error when trying to save your rollup, you may need to refresh the page. See Timeout Error When Trying to Save a Customizable Rollup for more information.
Since we already showed you an aggregate rollup above, it's only fair that we also show you how to create a single result operation rollup. And this one is particularly cool because it provides a lookup to another record. Cue the fireworks! Let's say you want to find the largest gift that a Contact donated and link to the Campaign that brought in the donation (from the Contact's record). Here's how you do it:
  1. Create a custom field on the Contact object that is related to the Campaign object. Name it Largest Gift Campaign.
  2. Create a new rollup with the following values:
    1. Target Object = Contact
    2. Target Field = Largest Gift Campaign
    3. Description = A lookup on the Contact record to Campaign associated with their largest donation, as determined by the Opportunity Amount field.
    4. Operation = Largest
    5. Time Frame = All Time
    6. Rollup Type = Opportunity > Contact (Hard Credit)
    7. Filter Group = Opportunities: Won (HC)
    8. Field to Roll Up: Opportunity: Campaign ID
    9. Amount Field: Opportunity Amount
  3. Click Save.
    A new rollup for Largest Gift Campaign on the Contact object.

    To see the updated field on the record right away, you'll need to manually recalculate rollups. Here's how it should look:

    The Contact record showing the Largest Gift Campaign field populated with a link to the Campaign record.

A note about creating custom fields for use in Customizable Rollups . . .

As we mentioned in the steps for creating a Customizable Rollup, the field you select as the Target Field must be a unique, writeable, custom field. And the field must exist before you create the Customizable Rollup.

It's also important to note that you should limit all users' access to the fields you're using as Target Fields in your rollups. We recommend that you make these custom fields read only for all users (including Sys Admins). Rollups will function properly even if the user creating the rollup or viewing the record with the rollup Target Field doesn't have Edit or View access to the field.

Clone a Customizable Rollup

To quickly create a new rollup that is similar to one that already exists, simply clone it. But keep in mind that you'll need to choose a unique Target field for your new rollup before you can save it.

  1. Go to the NPSP Settings tab. If you don't see the tab in your org, you can find it from the App Launcher.
  2. Click Donations | Customizable Rollups.
  3. Click Configure Customizable Rollups.
    Note
    If you need to go back to a previous screen while using Customizable Rollups, use the breadcrumbs at the top of the page. The back button will not work; it will always take you back to the NPSP Settings page.
  4. On the Customizable Rollups page, click the name of the rollup you want to clone.
  5. Click Clone.
  6. NPSP clones the entire rollup, with the exception of the Target field (since it must be unique!).
  7. Select a Target Field and make any other changes as needed.
  8. Click Save.

Deactivate or Delete a Customizable Rollup

You can delete or deactivate rollups as needed. Deactivating a rollup simply prevents NPSP from calculating the rollup moving forward, but you will still see it in the list of Customizable Rollups and could activate it again if needed. Deleting a rollup removes it from the list. Since NPSP no longer calculates deleted or deactivated rollups, you will see stale data in any deleted or deactivated rollups' Target fields. For any rollup you deactviate or delete, we recommend that you either clear the value out of the Target field or reuse the Target field in a new rollup.

To deactivate a rollup:

  1. In the list of Customizable Rollups, click the Name of the rollup you want to deactivate.
  2. Unselect the Active checkbox.
  3. Click Save.
    A rollup with the Active box highlighted

To delete a rollup:

  1. In the list of Customizable Rollups, click the Name of the rollup you want to delete.
  2. Click Delete.
  3. Click Delete again to confirm that you want to delete.