New content added weeklyLive
Master SQL with Adaptive AI.
Master SQL across 33 topics - Foundations, Joins and Aggregations, and Advanced SQL - guided by Leyaa's adaptive intelligence.
3Parts
33Topics
263Patterns
65hEst. duration
SQL Course
3 - part learning journey
Foundations
12 topics · 93 patterns
Joins and Aggregations
10 topics · 80 patterns
Advanced SQL
11 topics · 90 patterns
✦ Course Structure
Your SQL Journey in 3 Parts
Each part builds on the last - a deliberate progression from beginner to advanced.
Part 1: Foundations
Covers Database Fundamentals, Creating and Managing Tables, Inserting Data and 9 more topics.
12Topics
93Patterns
View topics
Part 2: Joins and Aggregations
Covers Aggregate Functions, GROUP BY and HAVING, INNER JOIN and 7 more topics.
10Topics
80Patterns
View topics
Part 3: Advanced SQL
Covers Window Functions Fundamentals, Advanced Window Functions, Common Table Expressions (CTEs) and 8 more topics.
11Topics
90Patterns
View topics
Curriculum
Everything You'll Learn
Explore every topic and pattern in the course.

SQL
3 parts · 33 topics · 263 patterns100% freeEvery pattern is free. Create a free account to start, and Leyaa tracks what you actually know.
Part 1: Foundations12 topics · 93 patterns
Beginner01
Database Fundamentals
8 patterns
Free
What is a databaseStart free Why databases over filesStart free What is SQLStart free How SQL communicates with the database engineStart free Relational model mental modelStart free Tables, rows, and columns conceptStart free Primary keys and uniquenessStart free SQL statement categories (DDL, DML, DQL, DCL)Start free
02
Creating and Managing Tables
9 patterns
Free
Why table design mattersStart free CREATE TABLE syntaxStart free Column data types (INT, VARCHAR, DATE, DECIMAL)Start free NOT NULL constraint behaviorStart free DEFAULT valuesStart free PRIMARY KEY constraintStart free AUTO_INCREMENT behaviorStart free DROP TABLE and ALTER TABLEStart free TRUNCATE vs DELETE vs DROPStart free
03
Inserting Data
7 patterns
Free
04
SELECT and Data Retrieval
7 patterns
Free
05
WHERE Clause and Filtering
10 patterns
Free
Why filtering is essentialStart free WHERE with comparison operatorsStart free WHERE with AND operatorStart free WHERE with OR operatorStart free WHERE with NOT operatorStart free WHERE with BETWEEN rangeStart free WHERE with IN listStart free WHERE with LIKE pattern matchingStart free WHERE with IS NULL and IS NOT NULLStart free Operator precedence in WHEREStart free
06
NULL Semantics and Three-Valued Logic
9 patterns
Free
Why NULL is not a valueStart free Three-valued logic (TRUE, FALSE, UNKNOWN)Start free NULL behavior in comparisonsStart free Why equals NULL failsStart free IS NULL vs equals NULLStart free NULL in AND, OR, NOT logicStart free NULL behavior in aggregate functionsStart free NULLs in JOIN conditionsStart free NULL in DISTINCT, GROUP BY, and ORDER BYStart free
07
Sorting and Limiting Results
8 patterns
Free
08
Updating Data
7 patterns
Free
09
Deleting Data
6 patterns
Free
10
String Functions
8 patterns
Free
11
Numeric and Date Functions
8 patterns
Free
Why built-in functions matterStart free ROUND, CEIL, FLOORStart free ABS and MOD functionsStart free CURRENT_DATE and CURRENT_TIMESTAMPStart free DATE_FORMAT and EXTRACTStart free DATE arithmetic (DATEDIFF, DATE_ADD)Start free YEAR, MONTH, DAY extractionStart free CAST and CONVERT for type changesStart free
12
SQL Dialect Differences
6 patterns
Free
Part 2: Joins and Aggregations10 topics · 80 patterns
Intermediate01
Aggregate Functions
8 patterns
Free
02
GROUP BY and HAVING
9 patterns
Free
Why grouping is neededStart free GROUP BY single columnStart free GROUP BY multiple columnsStart free How GROUP BY changes query executionStart free HAVING clause for filtering groupsStart free WHERE vs HAVING mental modelStart free GROUP BY with aggregate functionsStart free GROUP BY with ORDER BYStart free GROUP BY with NULL values behaviorStart free
03
INNER JOIN
8 patterns
Free
Why joins are neededStart free How the join engine matches rowsStart free INNER JOIN syntaxStart free INNER JOIN with ON conditionStart free Joining on primary key to foreign keyStart free INNER JOIN with multiple conditionsStart free INNER JOIN with table aliasesStart free Self join conceptStart free
04
LEFT and RIGHT JOIN
8 patterns
Free
Why outer joins are neededStart free LEFT JOIN execution behaviorStart free LEFT JOIN preserving all left rowsStart free RIGHT JOIN execution behaviorStart free LEFT JOIN with NULL result rowsStart free Finding unmatched rows with LEFT JOINStart free LEFT JOIN vs RIGHT JOIN decisionStart free Multiple LEFT JOINs in one queryStart free
05
Advanced Joins
8 patterns
Free
06
Subqueries
9 patterns
Free
Why subqueries are neededStart free Scalar subquery in SELECTStart free Subquery in WHERE clauseStart free Subquery with IN operatorStart free Subquery with EXISTS operatorStart free Correlated subquery execution modelStart free Subquery in FROM clause (derived table)Start free Subquery vs JOIN performance trade-offStart free Nested subqueriesStart free
07
Set Operations
7 patterns
Free
08
Table Constraints
9 patterns
Free
Why constraints matterStart free NOT NULL constraintStart free UNIQUE constraintStart free CHECK constraintStart free FOREIGN KEY constraintStart free Foreign key ON DELETE behaviorStart free Foreign key ON UPDATE behaviorStart free Composite primary keysStart free Constraint naming conventionsStart free
09
Table Relationships
7 patterns
Free
Why understanding relationships mattersStart free One-to-one relationship designStart free One-to-many relationship designStart free Many-to-many with junction tablesStart free Foreign key linking mental modelStart free Referential integrity enforcementStart free ER diagram to table mappingStart free
Part 3: Advanced SQL11 topics · 90 patterns
Advanced01
Window Functions Fundamentals
8 patterns
Free
Why window functions are neededStart free Window function vs GROUP BY mental modelStart free ROW_NUMBER functionStart free RANK and DENSE_RANK differenceStart free NTILE for distributionStart free OVER clause with PARTITION BYStart free OVER clause with ORDER BYStart free Window frame specification (ROWS BETWEEN)Start free
02
Advanced Window Functions
8 patterns
Free
Why advanced window functions matterStart free LAG function for previous row accessStart free LEAD function for next row accessStart free FIRST_VALUE and LAST_VALUEStart free NTH_VALUE functionStart free Running totals with SUM OVERStart free Moving averages with window framesStart free Percent of total with window functionsStart free
03
Common Table Expressions (CTEs)
9 patterns
Free
Why CTEs are neededStart free WITH clause syntaxStart free CTE as readable subquery replacementStart free Multiple CTEs in one queryStart free CTE referencing another CTEStart free Recursive CTE conceptStart free Recursive CTE for hierarchical dataStart free Recursive CTE for series generationStart free CTE vs subquery vs view decisionStart free
04
CASE Expressions
9 patterns
Free
Why CASE expressions are neededStart free Simple CASE syntaxStart free Searched CASE syntaxStart free CASE in SELECT for computed columnsStart free CASE in WHERE clauseStart free CASE in ORDER BYStart free CASE with aggregate functionsStart free Nested CASE expressionsStart free COALESCE and NULLIF as CASE shortcutsStart free
05
Transactions and Data Integrity
9 patterns
Free
Why transactions are neededStart free ACID properties mental modelStart free BEGIN TRANSACTION syntaxStart free COMMIT and ROLLBACK behaviorStart free Savepoints within transactionsStart free Transaction isolation levelsStart free Read phenomena (dirty reads, phantom reads)Start free Deadlock concept and preventionStart free Auto-commit behaviorStart free
06
Indexes and Query Performance
10 patterns
Free
Why indexes matterStart free How an index works (B-tree mental model)Start free CREATE INDEX syntaxStart free Single column indexStart free Composite index and column orderStart free Unique index behaviorStart free When indexes help and when they hurtStart free Index impact on INSERT and UPDATEStart free Covering index conceptStart free EXPLAIN plan for query analysisStart free
07
Stored Procedures and Functions
9 patterns
Free
Why stored procedures are neededStart free CREATE PROCEDURE syntaxStart free Parameters (IN, OUT, INOUT)Start free Variables and SET statementsStart free IF-ELSE in proceduresStart free WHILE loops in proceduresStart free CURSOR concept and usageStart free User-defined functionsStart free Function vs procedure decisionStart free
08
Triggers
8 patterns
Free
09
Database Design and Normalization
7 patterns
Free
10
Advanced Query Patterns
8 patterns
Free
Why query patterns matterStart free Pivot and unpivot conceptsStart free Running total without window functionsStart free Finding gaps in sequencesStart free Finding duplicates efficientlyStart free Top-N per group queryStart free Date range overlap detectionStart free Conditional aggregation patternStart free
Not just a course. A learning intelligence.
Leyaa doesn't just deliver content - it understands where you are, what you need, and how to get you there fastest.
Adaptive Diagnostics
Leyaa identifies which of the 263 patterns you've mastered and which need work - before you waste time on what you already know.
Pattern-Level Precision
Every pattern gets a verdict - Learn, Practice, or Skip - so your study time goes exactly where it counts.
Intelligent Pacing
Leyaa reads your velocity across the whole course and adapts your focus list dynamically, keeping you in the optimal learning zone.
Before & After Visibility
Every assessment creates a snapshot. Retake anytime to see exactly how much you've grown - topic by topic, pattern by pattern.
Learner Autonomy
Leyaa recommends, never restricts. Override any suggestion and explore at your own pace - the system tracks everything regardless.
Clear Learning Path
Foundations → Joins and Aggregations → Advanced SQL - a structured journey where each part sets you up perfectly for the next.
SQL
Ready to master SQL?
Start your journey today
Start your diagnostic now. Build mastery across all 33 topics in under 15 minutes.
33 Topics
263 Patterns
Personalized roadmap













