Rank
Allows the user to determine the rank of a value in a group of values, output as a new column. The function used depends on the data warehouse as below:
- Snowflake: Snowflake window function.
- Redshift: Redshift window function.
- BigQuery: BigQuery window function.
- Synapse: Synapse window function.
- Delta Lake: Delta Lake window function.
Properties
Name
= string
A human-readable name for the component.
Include Input Columns
= drop-down
Defines whether the component passes all input columns into the output.
Partition Data
= dual listbox
Defines how the input data is partitioned to perform the rank calculation. The calculation is then performed on each partition.
Ordering within partitions
= column editor
- Input Column: The input column name for sorting within the partitioned data. You can drag to reorder.
- Ordering: The order of the sorting: Ascending (Asc) or Descending (Desc).
Functions
= column editor
- Window Function:
- Rank determines the rank of a value in a group of values.
- Dense Rank determines the rank of a value in a group of values. The Dense Rank function differs from Rank in one respect: if two or more rows tie, there is no gap in the sequence of ranked values.
- Cumulative Distribution determines the cumulative distribution of a value within a window or partition.
- Percent Rank Calculates the percent rank of a given row. Row Number Determines the ordinal number of the current row within a group of rows, counting from 1.
- Output Column: The name of the output column that the window function will create.
Strategy
Generates a select statement with a window function in line using the OVER keyword. For more information, read:
- Snowflake window function.
- Delta Lake on Databricks window function.
- Amazon Redshift window function.
- Google BigQuery window function.
- Azure Synapse Analytics window function.
Video
Snowflake | Delta Lake on Databricks | Amazon Redshift | Google BigQuery | Azure Synapse Analytics |
---|---|---|---|---|
✅ | ✅ | ✅ | ✅ | ✅ |