← Back to Skills
Data & AnalyticsTechnologyPlatinum

Your SQL queries are running slow and need optimization.

SQL Performance Tuning Expert

PostgreSQL, MySQL, SQL Performance

expertv5.0

Best for

  • Diagnose and fix slow-running queries with execution times over 5 seconds
  • Analyze PostgreSQL EXPLAIN ANALYZE output to identify bottlenecks in complex joins
  • Design optimal B-tree and covering index strategies for high-traffic OLTP workloads
  • Rewrite correlated subqueries and CTEs for better optimizer cooperation

What you'll get

  • Execution plan breakdown identifying the most expensive operations with specific index recommendations and CREATE INDEX statements
  • Query rewrite transforming correlated subqueries to window functions with before/after performance comparisons
  • Comprehensive optimization strategy covering missing indexes, query restructuring, and configuration adjustments with implementation priority
Expects

Slow query with execution plan (EXPLAIN ANALYZE), table schemas, current indexes, and database engine details.

Returns

Specific optimization recommendations with implementation-ready SQL, performance impact estimates, and execution plan analysis.

What's inside

You are a SQL Performance Tuning Expert. You diagnose database performance problems and deliver specific optimization strategies with implementation-ready SQL, expected improvements, and monitoring guidance. - Prioritize root cause diagnosis (why sequential scans/locks occur) before recommending sol...

Covers

What You Do DifferentlyMethodologyWatch For
Not designed for ↓
  • ×Basic SQL syntax teaching or beginner query writing
  • ×Database schema design or entity relationship modeling
  • ×Database administration tasks like backup, replication, or user management
  • ×Application-level caching strategies or ORM configuration

SupaScore

89.4
Research Quality (15%)
9.1
Prompt Engineering (25%)
8.95
Practical Utility (15%)
8.8
Completeness (10%)
8.9
User Satisfaction (20%)
9
Decision Usefulness (15%)
8.85

Evidence Policy

Standard: no explicit evidence policy.

sql-optimizationquery-tuningexecution-plansindexingdatabase-performancepartitioningmaterialized-viewspostgresqlmysqlexplain-analyzequery-rewritingdatabase-profiling

Research Foundation: 8 sources (3 official docs, 4 books, 1 web)

This skill was developed through independent research and synthesis. SupaSkills is not affiliated with or endorsed by any cited author or organisation.

Version History

v5.03/25/2026

v5.5 final distill

v2.03/1/2026

Pipeline v4: rebuilt with 3 helper skills

v1.0.12/15/2026

Auto-versioned: masterfile quality gate passed (score: 87.0)

v1.0.02/15/2026

Initial release

Works well with

Need more depth?

Specialist skills that go deeper in areas this skill touches.

Common Workflows

Database Performance Analysis Pipeline

Complete database performance optimization workflow from query tuning to infrastructure monitoring setup

sql-performance-tuning-expertDatabase Performance Tunermonitoring-observability-designer

© 2026 Kill The Dragon GmbH. This skill and its system prompt are protected by copyright. Unauthorised redistribution is prohibited. Terms of Service · Legal Notice