18 Window Functions questions from the SQL bank, written for Indian campus drives and tech interviews. Every question has a verified answer and an AI-tutor explanation on placd.
Free to start: the 2-minute IT readiness check — six questions and a result.
A.SUM(...) OVER (ORDER BY ...) that accumulates values across ordered rows
B.divides rows into groups within which a window function operates
C.a function computing across a set of rows related to the current row without collapsing them
D.RANK leaves gaps in numbering after ties; DENSE_RANK does not
Answer + AI explanation with Pro
2. Which term means: "a function computing across a set of rows related to the current row without collapsing them"?
Senior
A.Window function
B.ROW_NUMBER
C.Running total
D.LAG / LEAD
Answer + AI explanation with Pro
3. Which statement is correct?
Senior
A.Window function — divides rows into groups within which a window function operates
B.Window function — SUM(...) OVER (ORDER BY ...) that accumulates values across ordered rows
C.Window function — a function computing across a set of rows related to the current row without collapsing them
D.Window function — assigns a unique sequential number to rows within a partition
Answer + AI explanation with Pro
4. What is ROW_NUMBER?
Mid
A.divides rows into groups within which a window function operates
B.assigns a unique sequential number to rows within a partition
C.a function computing across a set of rows related to the current row without collapsing them
D.RANK leaves gaps in numbering after ties; DENSE_RANK does not
Answer + AI explanation with Pro
5. Which term means: "assigns a unique sequential number to rows within a partition"?
Mid
A.LAG / LEAD
B.RANK vs DENSE_RANK
C.ROW_NUMBER
D.PARTITION BY
Answer + AI explanation with Pro
6. Which statement is correct?
Mid
A.ROW_NUMBER — a function computing across a set of rows related to the current row without collapsing them
B.ROW_NUMBER — RANK leaves gaps in numbering after ties; DENSE_RANK does not
C.ROW_NUMBER — SUM(...) OVER (ORDER BY ...) that accumulates values across ordered rows
D.ROW_NUMBER — assigns a unique sequential number to rows within a partition
Answer + AI explanation with Pro
7. What is RANK vs DENSE_RANK?
Senior
A.assigns a unique sequential number to rows within a partition
B.divides rows into groups within which a window function operates
C.a function computing across a set of rows related to the current row without collapsing them
D.RANK leaves gaps in numbering after ties; DENSE_RANK does not
Answer + AI explanation with Pro
8. Which term means: "RANK leaves gaps in numbering after ties; DENSE_RANK does not"?
Senior
A.Running total
B.ROW_NUMBER
C.RANK vs DENSE_RANK
D.PARTITION BY
Answer + AI explanation with Pro
9. Which statement is correct?
Senior
A.RANK vs DENSE_RANK — access a value from a previous or following row within the partition
B.RANK vs DENSE_RANK — divides rows into groups within which a window function operates
C.RANK vs DENSE_RANK — RANK leaves gaps in numbering after ties; DENSE_RANK does not
D.RANK vs DENSE_RANK — SUM(...) OVER (ORDER BY ...) that accumulates values across ordered rows
Answer + AI explanation with Pro
10. What is PARTITION BY?
Senior
A.access a value from a previous or following row within the partition
B.a function computing across a set of rows related to the current row without collapsing them
C.divides rows into groups within which a window function operates
D.assigns a unique sequential number to rows within a partition
Answer + AI explanation with Pro
11. Which term means: "divides rows into groups within which a window function operates"?
Senior
A.LAG / LEAD
B.PARTITION BY
C.Running total
D.RANK vs DENSE_RANK
Answer + AI explanation with Pro
12. Which statement is correct?
Senior
A.PARTITION BY — a function computing across a set of rows related to the current row without collapsing them
B.PARTITION BY — assigns a unique sequential number to rows within a partition
C.PARTITION BY — RANK leaves gaps in numbering after ties; DENSE_RANK does not
D.PARTITION BY — divides rows into groups within which a window function operates
Answer + AI explanation with Pro
13. What is LAG / LEAD?
Senior
A.a function computing across a set of rows related to the current row without collapsing them
B.access a value from a previous or following row within the partition
C.divides rows into groups within which a window function operates
D.RANK leaves gaps in numbering after ties; DENSE_RANK does not
Answer + AI explanation with Pro
14. Which term means: "access a value from a previous or following row within the partition"?
Senior
A.LAG / LEAD
B.RANK vs DENSE_RANK
C.ROW_NUMBER
D.PARTITION BY
Answer + AI explanation with Pro
15. Which statement is correct?
Senior
A.LAG / LEAD — SUM(...) OVER (ORDER BY ...) that accumulates values across ordered rows
B.LAG / LEAD — assigns a unique sequential number to rows within a partition
C.LAG / LEAD — access a value from a previous or following row within the partition
D.LAG / LEAD — divides rows into groups within which a window function operates
Answer + AI explanation with Pro
16. What is Running total?
Senior
A.assigns a unique sequential number to rows within a partition
B.access a value from a previous or following row within the partition
C.a function computing across a set of rows related to the current row without collapsing them
D.SUM(...) OVER (ORDER BY ...) that accumulates values across ordered rows
Answer + AI explanation with Pro
17. Which term means: "SUM(...) OVER (ORDER BY ...) that accumulates values across ordered rows"?
Senior
A.Running total
B.RANK vs DENSE_RANK
C.PARTITION BY
D.ROW_NUMBER
Answer + AI explanation with Pro
18. Which statement is correct?
Senior
A.Running total — divides rows into groups within which a window function operates
B.Running total — SUM(...) OVER (ORDER BY ...) that accumulates values across ordered rows
C.Running total — access a value from a previous or following row within the partition
D.Running total — assigns a unique sequential number to rows within a partition
Answer + AI explanation with Pro
Free to start
Start with a free readiness check
Sign up free for the 2-minute IT readiness check and a scored result. Answers, explanations and the AI tutor on every Window Functions question come with Pro.