DENSE_RANK

Important Notice: Migration of Documentation Website

Please be advised that our documentation website is currently undergoing a migration to a new platform. To ensure you have access to the most up-to-date information, we kindly request that you visit our new documentation website located at:

Official Snowflake Snowconvert Documentation

For any immediate assistance or if you encounter any issues, please contact our support team at [email protected].

Thank you for your understanding.

Applies to

Some parts in the output code are omitted for clarity reasons.

Description

This function returns the rank of each row within a result set partition, with no gaps in the ranking values. The rank of a specific row is one plus the number of distinct rank values that come before that specific row. (DENSE_RANK in Transact-SQL).

Sample Source Pattern

Syntax

IN -> SqlServer_01.sql
DENSE_RANK ( ) OVER ( [ <partition_by_clause> ] < order_by_clause > )  

Examples

Code:

Result:

  • SSC-EWI-0001: Unrecognized token on the line of the source code.

Last updated