partitionedAggBy
partitionedAggBy is a convenience method that performs an aggBy operation on the source table and wraps the result in a PartitionedTable.
Note
If the argument aggregations does not include a partition, one will be added automatically with the default constituent column name __CONSTITUENT__.
Syntax
Parameters
| Parameter | Type | Description |
|---|---|---|
| aggregations | Collection<? extends Aggregation> | The aggregation(s) to apply to the source table. |
| preserveEmpty | boolean | Whether to keep result rows for groups that are initially empty or become empty as a result of updates. Each aggregation operator defines its own value for empty groups. |
| initialGroups | Table | A table whose distinct combinations of values for the |
| keyColumnNames | String... | The names of the key columns to aggregate by. |
Returns
A PartitionedTable.
Examples
In this example, partitionedAggBy returns the source table, as partitioned by StreetName.