row_number
Aliases: rownumber (deprecated).
row_number() -> int64
Return the window index of the row within its groupby, when ordered by the orderby. Row indexes start at 1.
Domain
This is a window function (calculates over a group of multiple input rows using windowing).
Categories
Examples
make_col index:window(row_number(), group_by(category_id), order_by(item_cost))
Assigns an index to items, when ordered by cost, grouped by category. The cheapest item in each category will be given the index 1.
Updated 8 days ago