Data connectivity & integrationPipeline Builder TransformsAggregate

Aggregate

Supported in: Batch

Performs the specified aggregations on the input dataset grouped by a set of columns.

Transform categories: Aggregate, Popular

Declared arguments

  • Aggregations - List of aggregations to perform on the dataset.
    List<Expression<AnyType>>
  • Dataset - Dataset to perform aggregate on.
    Table
  • optional Group by columns - List of columns to group the dataset by when aggregating. If empty, no group by is applied.
    List<Column<AnyType>>

Examples

Example 1: Base case

Argument values:

  • Aggregations: [
    alias(
     alias: factor,
     expression:
    sum(
     expression: factor,
    ),
    )]
  • Dataset: ri.foundry.main.dataset.aggregate
  • Group by columns: [tail_number]

Input:

tail_numberairlinemilesfactor
XB-123foundry air1242
MT-222new airline11235
XB-123foundry airline3355
MT-222new air5654
KK-452new air2221
XB-123foundry airline11343

Output:

tail_numberfactor
XB-12310
MT-2229
KK-4521