Session
Index Skip Scans in Postgres 18: Optimizing Composite Index Performance
The leftmost Prefix Rule has long been a constraint in B-Tree index design, often forcing teams to maintain redundant indexes to cover different query patterns. Postgres 18 fundamentally transforms this with the introduction of Index Skip Scans, allowing the planner to utilize multi-column indexes even when the leading column is missing from the WHERE clause.
In this session, we will move past the feature announcement to explore the operational reality of Skip Scans. We will analyze the internal "jump" logic of the B-Tree traversal and use EXPLAIN (ANALYZE, BUFFERS) to compare execution costs between Postgres 17 and 18. I will share specific benchmarks on how column cardinality dictates the success of a skip scan and provide a framework for consolidating existing indexes to reduce storage overhead in high-volume environments.
Key Takeaways:
Internal Mechanics: How the Postgres 18 engine "skips" through index pages to find non-contiguous data.
The Cardinality Factor: Identifying the "sweet spot" for leading columns to ensure Skip Scans outperform traditional sequential scans.
Storage Optimization: Practical strategies for removing redundant indexes by leveraging multi-purpose composite indexes.
Planner Costing: How to interpret EXPLAIN output when Skip Scans are active and how the planner calculates the cost-benefit.
Session Metadata & Technical Requirements
Target Audience: * Primary: Database Administrators (DBAs), Backend Developers, and Data Architects.
Secondary: DevOps Engineers and Site Reliability Engineers (SREs) focused on performance tuning.
Experience Level: Intermediate. (Assumes basic knowledge of B-Tree structures and SQL performance tuning, but explains the new PG 18 mechanics from the ground up).
Preferred Session Duration: 45 Minutes (35-minute presentation + 10-minute Q&A).
First Public Delivery: Yes.
Session Track: PostgreSQL Internals, Performance Optimization, or Database Administration.
Technical Requirements & Logistics
Live Demo Environment: I will be demonstrating the Skip Scan behavior using a live PostgreSQL 18 instance (via Docker). I require a stable HDMI connection and a standard power outlet.
Key Learning Objectives
Deconstruct the internal B-Tree traversal logic that historically limited multi-column index usage.
Evaluate the specific conditions (low cardinality vs. high cardinality) where the PostgreSQL 18 Skip Scan provides the highest performance gains.
Implement a revised indexing strategy that reduces "index bloat" by leveraging more flexible composite indexes. Analyze execution plans (EXPLAIN ANALYZE) to identify when the planner is utilizing a Skip Scan versus a Sequential Scan.
Naresh Reddy Regalla
Cloud Solution Architect and Business Process Management Workflow Strategist
Chicago, Illinois, United States
Links
Please note that Sessionize is not responsible for the accuracy or validity of the data provided by speakers. If you suspect this profile to be fake or spam, please let us know.
Jump to top