Skip to content

Aggregation

Strata aggregates child values onto parent rows when you set the aggregate field on a column and enable aggregate display through the grid’s aggregation config.

aggregate valueResult
'sum'Sum of descendant values.
'avg'Mean of descendant values.
'min' / 'max'Min or max of descendant values.
'count'Count of descendant rows.
const columns: ColumnDef<Part>[] = [
{ id: 'qty', header: 'Qty', accessor: 'qty', aggregate: 'sum' },
];
<DataGrid
data={parts}
columns={columns}
aggregation={{ showParentAggregates: true, showFooterAggregates: true }}
/>;

For BOMs, aggregation.extendedQuantity can compute quantity rollups from a source quantity column into a target column.

Part #
Qty
Cost