← All Courses
Learn SQL & Databases
Coming SoonQuery, design, and optimize relational databases
SQL PostgreSQL MySQL Database Design Queries
Coming Soon
The language of data. SQL powers every relational database from PostgreSQL to MySQL to SQLite. Learn to write queries, design schemas, optimize performance, and manage data at scale.
This course covers SQL fundamentals through advanced query optimization, database design patterns, and production PostgreSQL administration.
Start Here — Learning Roadmap
A suggested path from zero to mastery. Follow these steps in order:
- Learn basic SELECT queries — Understand how to retrieve data from tables using SELECT, WHERE, ORDER BY, and LIMIT clauses
- Master filtering and aggregation — Use GROUP BY, HAVING, COUNT, SUM, AVG, and other aggregate functions to summarize data
- Understand JOINs — Connect multiple tables with INNER JOIN, LEFT JOIN, RIGHT JOIN, and CROSS JOIN to answer complex questions
- Write subqueries and CTEs — Break complex problems into readable parts using Common Table Expressions and nested queries
- Design schemas and normalize data — Learn 1NF through 3NF normalization, primary/foreign keys, and entity-relationship modeling
- Create and modify tables — Use DDL statements (CREATE, ALTER, DROP) and understand data types, constraints, and defaults
- Work with indexes and query plans — Read EXPLAIN output, create indexes strategically, and understand how the optimizer works
- Learn window functions — Use ROW_NUMBER, RANK, LAG, LEAD, and partition-based aggregates for analytics queries
- Administer a production database — Manage users, permissions, backups, replication, and monitoring in PostgreSQL
- Optimize at scale — Understand partitioning, materialized views, connection pooling, and performance tuning for large datasets
Official & Core Documentation
- PostgreSQL Documentation — Comprehensive PostgreSQL reference with tutorials, user guides, and internals documentation (All levels)
- MySQL Reference Manual — Official MySQL documentation covering all versions and SQL syntax (All levels)
- SQLite Documentation — Lightweight embedded database docs and SQL syntax reference (Beginner)
- MariaDB Knowledge Base — Community-driven documentation for the popular MySQL fork (Intermediate)
- W3Schools SQL Tutorial — Quick reference with a “Try it Yourself” editor for every concept (Beginner)
- SQL Style Guide — Consistent formatting conventions for readable, maintainable SQL (All levels)
- Mode SQL Tutorial — Structured SQL tutorial from basics through advanced analytics queries (Beginner)
- DevOps Roadmap — SQL — Visual step-by-step guide to learning SQL concepts in order (Beginner)
- PostgreSQL Wiki — Community-maintained tips, performance guides, and best practices (Intermediate)
GitHub Awesome Lists & Curated Collections
- awesome-sql — Tools and techniques for working with relational databases, including formatters, IDEs, and migration tools
- awesome-postgres — Curated list of PostgreSQL software, libraries, tools, and resources (9k+ stars)
- awesome-db-tools — Everything that makes working with databases easier, from GUI clients to schema diffing tools
- awesome-sql (mbiesiad) — Tutorials, docs, formatters, online education, tools, and more for SQL learners
- awesome-database — Broad collection of database libraries, resources, and tools across all database types
Interactive Courses & Hands-On Platforms
Free Courses
- SQLBolt — Interactive SQL lessons with live exercises, excellent for absolute beginners (Beginner)
- Select Star SQL — Interactive SQL book using real Texas death row data to teach query concepts (Beginner)
- SQLZoo — Interactive tutorials and quizzes covering joins, subqueries, and aggregates (Beginner)
- PostgreSQL Exercises — Practice PostgreSQL queries on a realistic club management dataset (Intermediate)
- SQL Easy — Clean, beginner-friendly interactive SQL tutorial with immediate feedback (Beginner)
- Khan Academy — Intro to SQL — Video tutorials paired with interactive coding challenges (Beginner)
- Kaggle SQL Micro-Course — Free hands-on SQL with BigQuery on real datasets (Beginner)
University & MOOC Courses
- Stanford — Databases Course — Stanford’s classic database course covering relational algebra and SQL (Intermediate)
- Oracle Dev Gym — Databases for Developers — Free 12-part Oracle SQL course with certificate (Beginner)
- IBM — Databases and SQL for Data Science — Coursera course covering SQL in the context of data science workflows (Beginner)
Practice & Challenges
- HackerRank SQL — SQL challenges from beginner to advanced with instant feedback (All levels)
- LeetCode Database Problems — SQL interview-style problems used by top tech companies (Intermediate)
- Exercism SQL Track — Mentored SQL exercises with community code review (Intermediate)
- DataLemur SQL Questions — Real SQL interview questions from FAANG companies (Intermediate)
- StrataScratch — SQL and Python interview questions sourced from real company interviews (Intermediate)
Video Courses & YouTube Channels
Structured Course Playlists
- freeCodeCamp — SQL Full Course — Complete 4-hour SQL beginner course covering all fundamentals (Beginner)
- CMU Database Course (Andy Pavlo) — Carnegie Mellon’s database systems course with free lectures covering internals (Advanced)
- Khan Academy — Intro to SQL — Video tutorials paired with interactive coding challenges (Beginner)
- Corey Schafer — SQLite & Python — Practical database usage in real Python applications (Intermediate)
Individual Creators & Channels
- Hussein Nasser — Database Engineering — Deep dives into database internals, indexing, ACID properties, and connection pooling (Advanced)
- Fireship — SQL in 100 Seconds — Quick conceptual overview of what SQL is and why it matters (Beginner)
- Ben Awad — Practical database usage in real-world full-stack applications (Intermediate)
Books & Long-Form Reading
Free Online Books
- Use The Index, Luke — Free web book on SQL indexing and tuning by Markus Winand (Intermediate)
- SQL Performance Explained — Deep dive into indexing and query optimization with visual explanations (Intermediate)
Essential Paid Books
- Learning SQL (3rd Ed.) — O’Reilly’s practical guide from basics to advanced queries (Beginner, Paid)
- Practical SQL (2nd Ed.) — Learn SQL through real-world datasets including census, earthquake, and taxi data (Beginner, Paid)
- SQL Antipatterns — Common SQL mistakes and how to avoid them in production (Intermediate, Paid)
- SQL Cookbook (2nd Ed.) — Favorite SQL techniques including window functions and pivoting (Intermediate, Paid)
- Designing Data-Intensive Applications — Martin Kleppmann’s essential guide to data systems architecture (Advanced, Paid)
Community, Practice & News
Forums & Discussion
- Database Administrators Stack Exchange — Expert Q&A for database professionals covering all major engines
- r/SQL — Active community for SQL questions, tips, and career advice
- r/PostgreSQL — PostgreSQL-specific discussions, news, and troubleshooting
- Stack Overflow — SQL Tag — Thousands of answered SQL questions with expert solutions
Newsletters & Blogs
- PostgreSQL Weekly — Weekly roundup of PostgreSQL news, articles, and tools
- DB Weekly — Weekly newsletter covering database technology news across all engines
- Planet PostgreSQL — Aggregated blog posts from PostgreSQL community members
Ecosystem Resources
- DataCamp SQL Courses — Interactive browser-based SQL with free introductory tier
- SQLAlchemy Documentation — Python SQL toolkit and ORM for application-level database work
- Prisma Documentation — Modern TypeScript ORM for Node.js and TypeScript applications
Tools & Environments
- DB Fiddle — Online SQL playground for testing and sharing database problems with MySQL, PostgreSQL, and SQLite support
- SQL Fiddle — Free, ad-free online SQL playground with multiple database engines
- SQLize Online — Run queries on MySQL, PostgreSQL, SQLite, MariaDB, and SQL Server in the browser
- RunSQL — Modern SQL playground with visual schema builder, query editor, and sharing capabilities
- PostgreSQL Playground (Aiven) — Free online PostgreSQL sandbox for testing queries without local setup
- DBeaver — Free multi-platform database tool supporting all major databases with visual query builder
- pgAdmin — Official PostgreSQL administration and development platform
- TablePlus — Modern, native database GUI for PostgreSQL, MySQL, SQLite, and more (free tier available)
- Beekeeper Studio — Open-source SQL editor and database manager with a clean, modern interface
- DataGrip — JetBrains IDE for databases with intelligent query console and schema navigation (Paid, free for students)
Cheat Sheets & Quick References
- SQL Cheat Sheet (LearnSQL) — Visual reference for SQL syntax covering SELECT, JOIN, GROUP BY, and subqueries
- PostgreSQL Cheat Sheet — Quick reference for common PostgreSQL commands and data types
- Window Functions Cheat Sheet — Visual guide to ROW_NUMBER, RANK, LAG, LEAD, and partition functions
- SQL JOIN Visualizer — Interactive visual tool showing how different JOIN types combine data
- DevHints SQL Cheat Sheet — Concise reference for MySQL and general SQL commands
Certification Paths
- Oracle Database SQL Certified Associate — Oracle’s entry-level SQL certification covering query fundamentals
- Microsoft Azure Data Fundamentals (DP-900) — Microsoft certification covering relational and non-relational data concepts
- Google Cloud Database Engineer — Google certification for designing and managing cloud databases
- PostgreSQL Certified Associate — EDB certification validating PostgreSQL administration and query skills