row_number
ranking window function (Databricks SQL)
Assigns a unique, sequential number to each row, starting with one, according to the ordering of rows within the window partition.
Returns
An INTEGER.
The OVER
clause of the window function must include an ORDER BY clause (Databricks SQL).
Unlike rank
and dense_rank
, row_number
breaks ties.
If the order is not unique, the result is non-deterministic.