Introduction to Execution Plans: How PostgreSQL Runs Your Query
Understand how PostgreSQL turns your SQL into an execution plan and why it picks one plan over another. Learn to inspect that plan with EXPLAIN and EXPLAIN ANALYZE.
- €150per person, before VAT
- 1 live session1 hour 30 minutes
- Theory and live demoswith Q&A
- Live online via Zoomin English
- Certificate of Attendance
Upcoming dates
Booking for a company or public body? Need a quote, purchase order or invoice? Email contact@dataegret.com and we'll arrange it.
What you'll learn
The session that opens the developer track. It builds the mental model the other sessions rely on: every query goes through the planner, which picks the plan it estimates to be cheapest.
The course covers
- Why SQL is declarative, and what that leaves for PostgreSQL to decide
- The query life cycle: parser, rewriter, planner and executor
- How the planner compares candidate plans and picks the one with the lowest estimated cost
- Execution plans as trees of nodes: scans, joins and the operations above them
- How table and index statistics feed the cost estimates
- EXPLAIN against EXPLAIN ANALYZE: the planned execution against the measured one
- Reading large plans with explain.depesz.com and explain.dalibo.com
Prerequisites
For developers who write SQL against PostgreSQL and have never looked at an execution plan, or have looked without knowing what to read first.
You should be comfortable writing SQL. The session is self-contained: no other session of the track is required.
For details see the course terms & conditions.
Syllabus
1What a query is
- SQL is declarative: you describe the result, PostgreSQL decides how to produce it.
- Why execution plans matter, and where performance problems appear.
2The query life cycle
- Parser, rewriter, planner and executor.
- A plan is a tree of nodes.
- How the planner chooses between candidate plans.
3A first look at EXPLAIN
- EXPLAIN and EXPLAIN ANALYZE.
- Tools for reading large plans.
Frequently asked questions
Who is this session for?
Developers who write SQL against PostgreSQL and want to understand what the database does with it. It assumes working SQL, not knowledge of PostgreSQL internals.
Can I book this session on its own?
Yes. Every session of the developer track is self-contained. It is also one of the seven sessions of High Performance SQL with Postgres, which you can book in full at a package price.
Is the session recorded?
No. The session is live, with time for questions, and is not recorded. You receive the handouts: the slides with the trainer's commentary and the full demo transcripts.
Can my company pay by invoice?
Yes — write to contact@dataegret.com and we invoice your company; card booking is also available online.
Instructors

Over 15 years of experience across Oracle, DB2, MySQL, SQL Server and PostgreSQL. A recognised PostgreSQL contributor, active in the community through committees, user groups and international conferences.

A specialist in monitoring, high availability, performance tuning and scalable system architecture, with a background in banking, finance and telecommunications.
Ready to book, or still deciding?
Live, small-group, taught by the people who run PostgreSQL in production. Questions first? Write to us — no sales pitch.
