MAXBY
Finds the maximum of a list of numbers, partitioned by the unique values of a separate column
Last updated
Finds the maximum of a list of numbers, partitioned by the unique values of a separate column
Last updated
MAXBY(column
, partition column
)
Returns the maximum value in a column when grouped by unique values within a partition column
MAXBY() is a window function, which performs MAX() except partitioned by the unique values of a separate column.
Arguments
Description
column
Column to search for maximum
partition column
Column containing unique values
Outputs the maximum value of a column when grouped by partition column