sql-pro
Optimizes SQL queries, designs database schemas, and troubleshoots performance issues. Use when a user asks why their query is slow, needs help writing complex joins or aggregations, mentions database performance issues, or wants to design or migrate a schema. Invoke for complex queries, window functions, CTEs, indexing strategies, query plan analysis, covering index creation, recursive queries, EXPLAIN/ANALYZE interpretation, before/after query benchmarking, or migrating queries between database dialects (PostgreSQL, MySQL, SQL Server, Oracle).
Install
With your agent
Install OMGSkills skill "jeffallan/claude-skills:sql-pro" into this agent's normal skills directory: call the OMGSkills MCP get_install_plan tool for your agent and run the script it returns (it installs only the pinned commit and verifies SKILL.md), and stop if MCP or the pin is unavailable. Do not overwrite or change existing skills without asking me.
Manual command
git clone https://github.com/Jeffallan/claude-skills /tmp/claude-skills && ln -s /tmp/claude-skills/skills/sql-pro ~/.claude/skills/sql-pro
From README
SQL Pro Core Workflow Schema Analysis - Review database structure, indexes, query patterns, performance bottlenecks Design - Create set-based operations using CTEs, window functions, appropriate joins Optimize - Analyze execution plans, implement covering indexes, eliminate table scans Verify - Run EXPLAIN ANALYZE and confirm no sequential scans on large tables; if query does not meet sub-100ms target, iterate on index selection or query rewrite before proceeding Document - Provide query explanations, index rationale, performance metrics Reference Guide Load detailed guidance based on context: | Topic | Reference | Load When | |-------|-----------|-----------| | Query Patterns | references/query-patterns.md | JOINs, CTEs, subqueries, recursive queries | | Window Functions | references/window-functions.md | ROWNUMBER, RANK, LAG/LEAD, analytics | | Optimization | references/optimization.md | EXPLAIN plans, indexes, statistics, tuning | | Database Design | references/database-design.md...
More from this repo
api-designer
Used when designing REST or GraphQL APIs, creating OpenAPI specifications, or planning API architecture.
architecture-designer
Used when designing new high-level system architecture, reviewing existing designs, or making architectural decisions.
atlassian-mcp
Integrates with Atlassian products to manage project tracking and documentation via MCP protocol.
