The RANK() Function for Numbering on Groups/Partitions in SQL Server