Change Data Grouping Order
When data is grouped in a level, it's automatically grouped in the order in which the columns are listed in the output level. This impacts the ordering of filters on drill-down levels that you add to a report. You can manually change group ordering if you need to.
The ordering of grouped data doesn’t affect the rows displayed in the grouped output level. It instead affects the ordering of the drill-down filters of the output level that you drill down into. This ordering is important since it impacts what records you can see when drilling down into the level.
You want the list of fields to start with a field that stores values that multiple records can share so the records can be grouped together by the field’s value. For instance, grouping records by incident status works well since multiple incidents have the same status. You would not want a unique field that stores unique values listed first in the drill-down filters. For instance, grouping by incident reference number does not work since the reference number is different for every incident.
For example, if you have a report with columns for Reference #, Subject, and Status Type, in that order, the output level’s data are also grouped in that order. If you then add a drill-down level, the fields in the drill-down menu’s Filter menu would be listed in this order.
- incidents.ref_no
- incidents.ref_no, incidents.subject
- incidents.ref_no, incidents.subject, incidents.status_id
Since incidents.ref_no
is the first ordering
field for a drill-down level, the drill-down level would return only
information related to the incident you drilled down on. If you wanted
to drill down on all incidents grouped by a different field, such
as the incidents’ status, you would need to reorder the grouping so incidents.status_id
is grouped first.