Top 50 sql query Interview Questions
The most frequently asked sql query questions across all roles and companies, ranked by real interview frequency. Updated daily.
Calculate Deliveroo's daily order volume and rolling 7-day average using a date spine, aggregation, and window functions.
Koch Minerals & Trading
DeliverooLLSEG (London Stock Exchange Group)Calculate acquisition-cohort retention within 30 days by channel using CTEs, joins, and conditional date ranges.
EvenUp
PlayStationDDelivery HeroCalculate Disney+ January cohort retention in February using a CTE, LEFT JOIN, date filters, and distinct user counts.
Turo
IntuitFind duplicate PenFed application records using a windowed count over business-key columns.
PENFED Credit Union
Quinstreet
CostarCalculate Beyond Finance daily sign-ups and their 30-day rolling average using CTEs and window functions.
Beyond FinanceHHEINEKEN InternationalYYASH TechnologiesRank Dayforce users by quarterly engagement and return the top 10% using aggregation and NTILE().
Dayforce
Lattice
Condé NastFind the second distinct highest salary in S&P Global employee data without using window functions.
S&P GlobalFFareportal
Itc InfotechSign up to see every question
Create a free account to unlock this list and practice real interview questions.
Use a CTE, GROUP BY, HAVING, and joins to identify duplicate transactions in the Syfe user ledger.
AvidXchange