PostgreSQL documentation for details:
https://www.postgresql.org/docs/9.6/queries-table-expressions.html#QUERIES-GROUPING-SETS
+
+An example of a report that could use this new feature is
+one based on the Circulation source with the following fields:
+
+ * Circulation -> Checkout / Renewal Library -> Short (Policy) Name (Raw Data)
+ * Circulation -> Checkout Date/Time (Year)
+ * Circulation -> Shelving Location -> Name (Raw Data)
+ * Circulation -> Circ ID (Count Distinct)
+
+Turning on the "Calculate grouping subtotals" checkbox would make
+the report show subtotals for each combination of
+short name, checkout year, and shelving location name.