Loading section...
FIRST, LAST, NTH VALUE
Concepts: sqlFirstLastValue
Positional Function Basics Each positional function accesses a specific row within the window frame. Understanding their syntax and default behaviors is essential for correct usage. FIRST_VALUE Every employee can see how far their salary is from the highest in their department. The person with the top salary has a gap of zero. This pattern is commonly used in compensation analysis to show each employee their relative position without revealing other individuals' exact salaries. The LAST_VALUE Frame Trap NTH_VALUE