Intermediate · 5h 30m · 19 lessons
Databases
Store, model, and query data with confidence using SQL.
What you'll learn
- ✦Explain what a database does that files and spreadsheets can't, and decide when you need one
- ✦Model data as tables with rows, columns, the right data type for each column and a primary key
- ✦Write
SELECTqueries withWHERE,ORDER BYandLIMITthat return exactly the rows you need - ✦Calculate summaries with
COUNT(*)and other aggregates, and predict what they return - ✦Connect tables with foreign keys and combine them with
INNER JOINandLEFT JOIN - ✦Apply basic normalisation and decide which columns to index so queries stay fast
- ✦Change data safely with
INSERT,UPDATE,DELETEand transactions - ✦Summarise data with
GROUP BY, handleNULLcorrectly, and decide when a NoSQL database fits
Part of these career paths
- Backend Developer path · course 4 of 14
- Full-Stack Developer path · course 5 of 14
Certification projects
Build 4 projects to earn your certificate
Hands-on work that proves you can apply what you learned — part of the certificate requirements.
Syllabus
Module 1 · 1h 6m
Foundations Free
What you'll be able to do
- Can explain what a database and its DBMS do that a shared spreadsheet can't, and decide when you need one
- Can turn any list into a table, knowing when a change adds a row, a column or a new table
- Can choose a data type for each column, including exact money, dates and phone numbers
- Can pick a primary key that stays unique, never empty and stable
Module 2 · 1h 33m
Querying with SQL Locked
What you'll be able to do
- Can turn a plain-English question into a SELECT … FROM … query and predict the rows and columns it returns
- Can write a WHERE with AND, OR, brackets and the right comparison so exactly the intended rows come back
- Can write a top-N query with ORDER BY and LIMIT, and run your own queries in the SQL playground
- Can summarise rows with COUNT, SUM, AVG, MIN and MAX, and predict what COUNT(*) and COUNT(column) return
Module 3 · 1h 21m
Relationships & performance Locked
What you'll be able to do
- Can link two tables with a foreign key on the right side of a one-to-many relationship and predict which inserts it rejects
- Can choose INNER or LEFT JOIN for a question and predict how many rows the join returns
- Can spot a fact stored twice and split it into its own table so updates change one row
- Can pick the column to index for a slow query and weigh what each index costs on writes
Module 4 · 47m
Changing data Locked
What you'll be able to do
- Can add one or many rows with an INSERT that names its columns and lets the id fill itself
- Can preview an UPDATE or DELETE with a SELECT and predict exactly which rows it will change
- Can wrap related changes in a transaction and predict the data after COMMIT, ROLLBACK or a crash
Module 5 · 47m
Grouping & growing Locked
What you'll be able to do
- Can summarise data per group with GROUP BY and filter the groups with HAVING
- Can find missing values with IS NULL and predict how COUNT, SUM and AVG treat NULL
- Can decide whether an app's data suits a relational database or a document, key-value or graph store