Aggregate String

Aggregate strings across rows by concatenating them together, and grouping by other columns.

Uses a text separator to aggregate the string values together, and returns a single column where the rows are the aggregated strings.

Parameters

Example

product = rasgo.get.dataset(75)

ds2 = product.aggregate_string(group_by=['PRODUCTLINE'],
                agg_columns=['PRODUCTKEY', 'ENGLISHPRODUCTNAME'],
                sep=', ',
                distinct='FALSE',
                order='ASC')
ds2.preview()

Source Code

Last updated