Skip to content

SQL Window functions are among the most powerful features in modern SQL. They allow you to perform calculations across sets of rows that are related to the current row.

Understanding the OVER Clause

The OVER clause is what makes a function a window function. It defines the window of rows the function operates on.

Common Window Functions

ROW_NUMBER, RANK, DENSE_RANK, LAG, LEAD, and aggregate functions like SUM and AVG can all be used as window functions.

TAGS sqldata-engineeringdatabase