|
| 1 | +# SQL & PostgreSQL Curriculum — Vets Who Code |
| 2 | + |
| 3 | +**Goal:** Train veterans to confidently use PostgreSQL for storing, retrieving, and managing mission-critical data. |
| 4 | + |
| 5 | +--- |
| 6 | + |
| 7 | +## Module 1: PostgreSQL Basics |
| 8 | + |
| 9 | +- History & military roots (DARPA funding, Postgres origins) |
| 10 | +- Installing and connecting to PostgreSQL |
| 11 | +- Understanding databases, tables, rows, columns |
| 12 | +- Core SQL categories: DDL, DML, DQL, DCL, TCL |
| 13 | +- PostgreSQL data types (numeric, text, date/time, JSON) |
| 14 | + |
| 15 | +--- |
| 16 | + |
| 17 | +## Module 2: Querying Data |
| 18 | + |
| 19 | +- `SELECT` basics and selecting specific columns |
| 20 | +- Filtering with `WHERE` (`=`, `>`, `<`, `LIKE`, `BETWEEN`, `IN`) |
| 21 | +- Removing duplicates with `DISTINCT` |
| 22 | +- Sorting results with `ORDER BY` |
| 23 | +- Using `LIMIT` for result control |
| 24 | + |
| 25 | +--- |
| 26 | + |
| 27 | +## Module 3: Modifying Data |
| 28 | + |
| 29 | +- Adding data with `INSERT` |
| 30 | +- Changing data with `UPDATE` |
| 31 | +- Removing data with `DELETE` and `TRUNCATE` |
| 32 | + |
| 33 | +--- |
| 34 | + |
| 35 | +## Module 4: Working with Multiple Tables |
| 36 | + |
| 37 | +- Understanding primary & foreign keys |
| 38 | +- Joining tables: `INNER`, `LEFT`, `RIGHT`, `FULL` |
| 39 | +- Aggregating with `GROUP BY` and `HAVING` |
| 40 | +- Using subqueries |
| 41 | + |
| 42 | +--- |
| 43 | + |
| 44 | +## Module 5: Database Design & Management |
| 45 | + |
| 46 | +- Normalization basics (1NF, 2NF, 3NF) |
| 47 | +- Constraints: `NOT NULL`, `UNIQUE`, `PRIMARY KEY`, `FOREIGN KEY`, `CHECK` |
| 48 | +- Creating & altering tables (`CREATE`, `ALTER`, `DROP`) |
| 49 | +- Indexes for performance |
| 50 | + |
| 51 | +--- |
| 52 | + |
| 53 | +## Module 6: Advanced PostgreSQL Features |
| 54 | + |
| 55 | +- Window functions (`ROW_NUMBER`, `RANK`) |
| 56 | +- Common Table Expressions (CTEs) |
| 57 | +- JSON and Array support in Postgres |
| 58 | +- Using `EXPLAIN` for query optimization |
| 59 | + |
| 60 | +--- |
| 61 | + |
| 62 | +## Module 7: PostgreSQL Administration |
| 63 | + |
| 64 | +- Roles and permissions (`GRANT`, `REVOKE`) |
| 65 | +- Backups & restores (`pg_dump`, `pg_restore`) |
| 66 | +- Basic performance tuning |
| 67 | +- Maintenance tasks (`VACUUM`, `ANALYZE`) |
| 68 | + |
| 69 | +--- |
| 70 | + |
| 71 | +## Capstone Project |
| 72 | + |
| 73 | +- Build and query a PostgreSQL database using real-world veteran-related datasets |
| 74 | +- Create reports and dashboards using SQL queries |
| 75 | +- Implement a role-based permission system |
0 commit comments