Section 1: PostgreSQL Architecture and Version Lifecycle
- How clusters, databases, schemas and tables relate to each other
- Main processes, shared buffers and WAL in brief, and MVCC and why vacuum is needed
- The 5-year support policy, PostgreSQL 18 as the current stable release, and PostgreSQL 19 in beta
- The risks of running a version that is out of support
Section 2: Lab: Installing PostgreSQL 18 and the Tools
- Run PostgreSQL 18 with Docker and a volume for persistent data
- Use psql like a professional: l, dn, dt, d, x and display settings
- Use pgAdmin 4: register a server, the Query Tool and the ERD Tool for reading table structures
- Load the NovaMart sample database and explore its tables
Section 3: Configuration That Affects Reporting
- postgresql.conf, ALTER SYSTEM and the difference between reload and restart
- work_mem and its effect on sorting and aggregating large report queries
- statement_timeout to stop report queries that run too long
- Logging settings that capture slow queries for analysis
Section 4: Roles, Privileges and Schemas for the Reporting Team
- Roles, users and groups in PostgreSQL, and privilege inheritance
- GRANT and REVOKE at database, schema, table and column level
- A read-only reporting role, and ALTER DEFAULT PRIVILEGES for future tables
- Predefined roles such as pg_read_all_data and pg_monitor
- Configure pg_hba.conf and SCRAM-SHA-256 so users can connect remotely
Section 5: Lab: Basic Backup and Restore
- pg_dump and pg_restore: file formats and restoring selected tables
- pg_dumpall for backing up roles and global objects
- Keeping a separate copy of the database for reporting, apart from the production system
- ANALYZE and the statistics the query planner uses after a large data load
Section 6: Workshop Day 1: NovaMart Sales Reporting
- Install PostgreSQL 18 with Docker and load the NovaMart database
- Create the sales and report schemas
- Create a read-only report_reader role and test connecting with it from pgAdmin 4
- Workshop: back up and restore the database ready for the next day