Defining Roll-Up Summaries

Available in: Contact Manager, Group, Professional, Enterprise, 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”

Define roll-up summary fields on the object that is on the master side of a master-detail relationship. If a relationship does not already exist, first create a master-detail relationship between the master object that displays the value and the detail object containing the records you are summarizing.

To define 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 should be on the master side of a master-detail relationship. For instructions on creating a custom field, see Creating Custom Fields.
  2. Choose the Roll-Up Summary field type, and click Next.
  3. Enter a field label and any other attributes. Click Next.
  4. Select the object on the detail side of a master-detail relationship. This object contains the records you want to summarize.
  5. Select the type of summary:
    Type Description
    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 your 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 organization's default language.
  7. Click Next.
  8. Set the field-level security to determine whether the field should be visible for specific profiles, and click Next.
  9. Choose the page layouts that should 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.
  10. Click Save to finish or Save & New to create more custom fields.
See Also:
About Roll-Up Summary Fields
© Copyright 2000–2013 salesforce.com, inc. All rights reserved.
Various trademarks held by their respective owners.