Roll-up Summary Fields

In the previous discussion on master-detail relationship, there was a rather tempting mention of a feature called Roll-up Summary Fields.

Roll-up Summary Fields, sometimes referred to as RSFs, perform different types of calculations, based on the child records in a master-detail relationship. A Roll-up Summary Field is available just like any other field, in pages, related list views and reports.

You can use Roll-up Summary Fields to obtain the following aggregates:

  • COUNT - holds the number of child records in the master-detail relationship

  • SUM - holds the sum of the values of the child record field indicated

  • MAX - holds the maximum value of the child record field indicated

  • MIN - holds the minimum value of the child record ...

Get The Developer’s Guide to the Force.com Platform now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.