Applies to: Databricks SQL Databricks Runtime
Returns an array consisting of all values in
expr within the group. This function is a synonym for array_agg aggregate function.
collect_list ( [ALL | DISTINCT] expr ) [FILTER ( WHERE cond ) ]
This function can also be invoked as a window function using the
expr: An expression of any type.
cond: An optional boolean expression filtering the rows used for aggregation.
An ARRAY of the argument type.
The order of elements in the array is non-deterministic.
NULL values are excluded.
DISTINCT is specified, the function collects only unique values and is a synonym for collect_set aggregate function.