Loading
Extend Salesforce with Clicks, Not Code
Table of Contents
Select Filters

          No results
          No results
          Here are some search tips

          Check the spelling of your keywords.
          Use more general search terms.
          Select fewer filters to broaden your search.

          Search all of Salesforce Help
          Create a Roll-Up Summary Field

          Create a Roll-Up Summary Field

          Define a roll-up summary field on the object that’s on the master side of a master-detail relationship.

          Required Editions

          Important
          Important Where possible, we changed noninclusive terms to align with our company value of Equality. We maintained certain terms to avoid any effect on customer implementations.
          Available in: both Salesforce Classic and Lightning Experience
          Available in: Contact Manager, Group, Professional, Enterprise, Performance, Unlimited, Developer, and Database.com Editions
          User Permissions Needed
          To view roll-up summary field definitions: View Setup and Configuration
          To edit roll-up summary field definitions: Customize Application

          If a relationship doesn’t exist, first create a master-detail relationship between the master object that displays the value and the detail object that contains the records you’re summarizing.

          To create a roll-up summary field:

          1. Create a custom field on the object where you want the field displayed. Summary fields summarize the values from records on a related object, so the object on which you create the field is on the master side of a master-detail relationship. For instructions on creating a custom field, see Create Custom Fields..
          2. Choose the Roll-Up Summary field type, and click Next.
          3. Enter a field label and any other attributes, and click Next.
          4. Select the object on the detail side of a master-detail relationship. This object contains the records that you want to summarize.
          5. Select the type of summary.
            COUNT Totals the number of related records.
            SUM Totals the values in the field you select in the Field to Aggregate option. Only number, currency, and percent fields are available.
            MIN Displays the lowest value of the field you select in the Field to Aggregate option for all directly related records. Only number, currency, percent, date, and date/time fields are available.
            MAX Displays the highest value of the field you select in the Field to Aggregate option for all directly related records. Only number, currency, percent, date, and date/time fields are available.
          6. Enter filter criteria if you want a selected group of records in your summary calculation. If your organization uses multiple languages, enter filter values in your org’s default language.
            When you use picklists to specify filter criteria, the selected values are stored in the org’s default language. If you edit or clone existing filter criteria, first set the Default Language on the Company Information page to the same language that was used to set the original filter criteria. Otherwise, it’s possible that the filter criteria aren’t evaluated as expected.
          7. Click Next.
          8. Set the field-level security to determine whether the field is visible for specific profiles, and click Next.
          9. Select the Dynamic Forms-enabled Lightning record pages that should include the field, then click Next.
            If you don’t have any Dynamic Forms-enabled Lightning record pages for the object, this step doesn’t appear.
          10. Choose the page layouts where you want to display the field.
            The field is added as the last field in the first two-column section on the page layout. For user custom fields, the field is automatically added to the bottom of the user detail page.
          11. Click Save to finish or Save & New to create more custom fields.
           
          Loading
          Salesforce Help | Article