Databases
Hands-on database skills: SQL, schema design, indexing, and working with an ORM.
Beginner
- What is a Database?: Software that stores data in an organized shape you can search, filter, and change directly.
- Tables, Rows & Columns: The spreadsheet-like grid that relational databases use to organize data.
- Primary Keys & Foreign Keys: How a database identifies one exact row, and how rows in different tables point to each other.
- Basic SQL Queries: The four core commands (SELECT, INSERT, UPDATE, DELETE) for reading and changing data.
- Filtering & Sorting: Pick the rows you want with WHERE, and set the order they come back in with ORDER BY.
Intermediate
- Joins: Combine matching rows from two or more tables into one result, using the foreign keys that link them.
- Aggregation: Turn many rows into a summary value, like a count, total, or average.
- Indexes: A lookup structure that lets the database jump to matching rows instead of scanning the whole table.
- Normalization: Organize tables so each fact is stored in exactly one place, not copied everywhere it's needed.
- Constraints: Rules on a table's columns that the database enforces, so invalid data can't be saved.
- Transactions & ACID: Group several operations into one all-or-nothing unit, so a failure never leaves data half-changed.
- ORMs: A library that lets your code work with database rows as objects and writes the SQL for you.
- PostgreSQL in Depth: PostgreSQL features beyond standard SQL: richer data types, auto-incrementing ids, and the psql client.
- Subqueries & CTEs: Nest one query in another, or name a step with WITH, to split a complex question into readable pieces.
- Pagination: Return a large result in smaller pages, using LIMIT/OFFSET or keyset pagination.
Advanced
- Database Migrations: Small, versioned scripts that change a schema over time, so every environment gets the same structure in the same order.
- Query Optimization: Read the database's plan for a query to find out why it's slow and how to speed it up.
- Connection Pooling: Keep a small set of open database connections to reuse, instead of opening a new one for every request.
- NoSQL Data Modeling: Shape documents around how they'll be read, often embedding related data instead of splitting it across tables.
- Window Functions: Calculate across related rows, like a running total or a rank, without collapsing them as GROUP BY does.
- Upsert & Conflict Handling: Insert a row, or update it if it already exists, in one atomic statement.