Rank in column
Ranking values in a column is when you set every value as a number either higher than or lower than the other values. The lowest value (rank = 1) indicates the value with the first rank in your set of values.
Here's an example of a percent change calculation:

And here's the SQL used to generate it:
ROW_NUMBER() OVER(ORDER BY ${pages.page_view_count} DESC)
In general, the SQL used for calculating the rank in a column has just one important column and one other important parameter:
column_i_want_to_rank- this is the column that you want to rankASCandDESC- if you want to have the biggest values with rank = 1, then you need to addDESCto yourORDER BYclause. If you want the smallest values with rank = 1 then you can addASCto yourORDER BYclause (this isn't required, since the ordering isASCby default).
๐ Here's the SQL you can copy-paste to calculate your rank in columnโ
ROW_NUMBER() OVER(ORDER BY ${table.column_i_want_to_rank} DESC)