EPISODE · Aug 29, 2026 · 9 MIN
Why Database Query Planning Uses Cost Models
from Database Tech with Fexingo: SQL, NoSQL, and Data Storage Conversations · host Fexingo
In this episode of Database Tech with Fexingo, Lucas and Luna dive into the hidden complexity of database query planning. They explore how modern databases decide between a sequential scan and an index scan, why the planner's cost model matters more than raw speed, and how a single bad cardinality estimate can turn a two-millisecond query into a two-second disaster. Using a concrete example of a users table with a status column, they walk through the planner's decision process, the role of statistics and histograms, and the dangers of stale or misleading data. They also touch on how parameterized queries can break the optimizer's assumptions and why sometimes a hint is the last resort. Tune in to understand the unsung hero of database performance: the cost model that runs behind every query you write. #DatabaseQueryPlanning #CostModels #CardinalityEstimation #SQLOptimizer #IndexScan #SequentialScan #DatabaseStatistics #QueryOptimization #DatabasePerformance #PostgreSQL #MySQL #TechPodcast #DataEngineering #Business #FexingoBusiness #BusinessPodcast #DatabaseTech #SQL Keep every episode free: buymeacoffee.com/fexingo
Embed this episode
Ready to play
Why Database Query Planning Uses Cost Models
No transcript for this episode yet
Similar Episodes
No similar episodes found.
Similar Podcasts
No similar podcasts found.