You are currently viewing How To Create Roll-Up Summary Fields In Salesforce

How To Create Roll-Up Summary Fields In Salesforce

Sharing is caring!

Roll-up summaries are one of the effective tools in Salesforce that you can use to analyze your data without running summary reports. They can give you contact or household-specific data to view and provide a brief overview of related donations so you can get a glimpse of the donor’s engagement with your organization.

Roll-up summary fields are used to calculate related record values and to display master records. The Roll-up field automatically checks for the change in related records and then automatically updates the Master record. The field can display the count, sum, maximum, or minimum value of related records that work on a numeric, currency, or date field. This can only be created when the parent-child relationship is a master-detail relationship. You can create roll-up summaries of the Opportunities on account records or any main object that summarizes the fields from its detailed record.

Now let’s discuss the steps to create a Roll-up Summary Field in the Quote object to count the number of line items created for that.

Here are the steps you need to take to create a summary field in Salesforce:

Steps To Create Roll-Up Summary Fields

  •  Go to Object Manager from Set Up
  •  choose Account ->Fields & Relationships
  •  Click on the New button

  • Select ‘Roll-Up Summary’ and click on Next. Enter the details

  • Click Next 
  • Choose Opportunities for Object to Summarize and select the sum of Roll up type with Field to aggregate is Quantity

Roll-up summary field has the following functions:

  1. Count()
  2. Min()
  3. Max()
  4. Sum()

Roll-up summary field functions:

1. Count: Used to count the number of child records that exist for the parent record.

2. Sum:  Calculates the sum of the values of a specified field on a child record. Number, currency, and the percent fields are available for sum calculations. As  ‘Sum’ is selected, you must provide a ‘Field to Aggregate’. It contains the list of numeric fields in the Child object. It will calculate the sum of the Quantity of Opportunity Line Items and put it on the rollup field.

3. Min: Used to calculate the field’s minimum value in all child records.

4. Max: Used to calculate the maximum value of a field in all child records.

Now Establish field-level security-

Click Next.

Click on save.
After that, Your Roll-up Summary field is created. So here, we have selected the Roll up type as Sum because we are calculating the sum of Quantity, and because of roll-up type, the sum of Quantities is displayed on Account.


Suppose the account name is Test and Test has One Opportunity, but this Opportunity has 2 Opportunity line Items. One Opportunity line Item has 5 quantities, and the other has 10 quantities. Then this Sum of Quantity roll-up field would have 15 quantities.

Similarly, we would create a Number of OpportunityLineItems Roll up fields on Account to calculate the total number of OpportunityLineItems. In this case we would select Count as the Roll Up type because Count is used to count the number of child records present for the parent record.

  • Click on save

Limitations on Roll-Up Summary Fields in Salesforce

1. A Roll-up summary can only be created for records that have a master-detail relationship.

2. Only 25 roll-up summary fields can be created for an object.

3. Long text areas, multi-select picklist, Description fields, system fields such as Last Activity, cross-object formula fields, and lookup fields cannot be used in roll-up summary filters.

4. A Master-detail relationship can’t be changed to a lookup relationship after creating a roll-up summary field on an object.

5. When you refer to a roll-up summary field in a list view or report, you cannot use certain qualifiers, including Starts with Contains, Does not contain, Includes, Excludes, and Within.


Salesforce Roll-Up Summary Fields summarizes data from several related detail records and automatically displays the output on the master record. They can be used to display the total, maximum, minimum values of a field in a related list and the total number of all the records listed in a related list. They are only available for master objects in a master-detail relationship. Once a Roll-Up Summary Field on an object is created, the master-detail relationship cannot be converted into a lookup relationship.

Are you looking to boost your business ROI and increase sales by hiring the best Salesforce Implementation partner? Hire Cloud Analogy’s Salesforce Implementation experts who would help you with the best yet effective business plans and strategizes for Salesforce implementation success, and bring revolutionary outcomes within your business.


Ajay Dubedi

CEO | Founder
Ajay Dubedi, the founder and CEO of Cloud Analogy, is a prominent Salesforce Sales, Service, and Marketing cloud Consultant with a rich expertise in handling challenging business models. Ajay has assisted and implemented solutions in industries comprising Banking, Health Care, Networking, Education, Telecommunication and Manufacturing. Ajay is globally acclaimed for his extensive experience in APEX Programming, VisualForce pages, Triggers, Workflows, Page Layouts, Roles, Profiles, Reports & Dashboards.

Hire the best Salesforce Implementation Partner. Choose Cloud Analogy, the world's most preferred Salesforce Implementation Company that provides custom CRM Implementation services.

Leave a Reply

× How can I help you?