178.Rank Scores


  • 0
    Y

    """
    select m.score, rank from
    (select score, rank() over (order by score Desc) from Scores
    group by score) as r
    right join
    Scores as m
    on r.score = m.score
    order by m.score desc;
    """
    This works for me in postgres.


Log in to reply
 

Looks like your connection to LeetCode Discuss was lost, please wait while we try to reconnect.