A structured, pattern-focused journey through the LeetCode SQL-50 Study Plan, aimed at building strong real-world SQL fundamentals rather than just collecting solutions.
This repository reflects how I think in SQL β from basic SELECT queries to complex JOINs and Window Functions.
- Solved problems topic-wise (SELECT β JOINS β AGGREGATIONS β SUBQUERIES β WINDOW FUNCTIONS)
- Focused on query patterns and reasoning, not memorizing syntax
- Wrote clean, readable SQL with comments explaining why the solution works
- Prioritized clarity, correctness, and interview-ready approaches
- LEFT JOIN + NULL filtering for exclusion-based queries
- INNER vs LEFT JOIN decision-making
- WHERE vs HAVING in aggregation logic
- Subqueries vs JOINs: use cases and trade-offs
- Window functions for ranking, running totals, and analytics
Each folder represents a SQL concept, and each file corresponds to a LeetCode problem. LeetCode-SQL-50/ βββ Select/ βββ Basic-Joins/ βββ Aggregations/ βββ Subqueries/ βββ Window-Functions/
Each .sql file contains a clean, well-commented solution explaining the reasoning behind the query.
This is not just a collection of answers.
It demonstrates:
- Structured learning
- Strong SQL fundamentals
- Ability to reason about data problems
- Clean, maintainable query writing
- Apply these SQL patterns to real-world datasets
- Practice SQL interview questions
- Explore performance and analytical use cases