ROW_NUMBER
Description
Numbers the output of a result set. More specifically, returns the sequential number of a row within a partition of a result set, starting at 1 for the first row in each partition. (ROW_NUMBER in Transact-SQL).
Sample Source Pattern
Syntax
ROW_NUMBER ( )
OVER ( [ PARTITION BY value_expression , ... [ n ] ] order_by_clause ) Snowflake SQL complete documentation
ROW_NUMBER( )
-- ** SSC-EWI-0001 - UNRECOGNIZED TOKEN ON LINE '2' COLUMN '5' OF THE SOURCE CODE STARTING AT 'OVER'. EXPECTED 'BATCH' GRAMMAR. CODE '80'. **
-- OVER ( [ PARTITION BY value_expression , ... [ n ] ] order_by_clause )Examples
Code:
Output:
Code:
Output:
Related EWIs
SSC-EWI-0001: Unrecognized token on the line of the source code.
Last updated
