What problem does it solve?
database-optimizer helps you diagnose and fix slow queries and inefficient execution by turning raw performance signals (like slow query logs and EXPLAIN plans) into practical, measurable tuning actions.
Core Features & Use Cases
- Execution plan-driven optimization: Start from EXPLAIN/EXPLAIN ANALYZE to identify real bottlenecks (sequential scans, join strategy issues, misestimates, I/O hotspots) before changing anything.
- Index and query redesign: Propose targeted index strategies (including composite, covering, partial, and expression indexes) and rewrite queries to avoid common performance traps.
- DBMS-specific tuning: Apply PostgreSQL and MySQL configuration and maintenance guidance to improve cache efficiency, reduce lock contention, and maintain healthy statistics.
Use cases: optimizing a PostgreSQL report query that regresses after data growth, or improving a MySQL endpoint stuck on table scans by redesigning indexes and rewriting the slow query pattern.
Quick Start
Use the database-optimizer skill to optimize the query for your database by analyzing your EXPLAIN plan first, then proposing an index/query/config change set, and validating the improvement with before/after measurements.