Spark SQL - Windowing Functions - Ranking Functions

preview_player
Показать описание
Let us talk about ranking functions within each group.

* We have functions like rank, dense_rank, row_number, etc
* We need to create a spec for most of the ranking functions by
specifying grouping column under PARTITION BY clause and then
sorting column under ORDER BY clause.
* Some realistic use cases
* Assign rank to employees based on salary within each
department
* Assign ranks to products based on revenue each day or month

Connect with me or follow me at
Рекомендации по теме