indexing-query-optimization

Community

Design safe indexes from real query plans.

Authormachenjie
Version1.0.0
Installs0

System Documentation

What problem does it solve?

This Skill prevents slow or risky database changes by replacing blind index addition with index designs driven by actual predicates, sort requirements, cardinality, and execution plan evidence.

Core Features & Use Cases

  • Named-Query-First Index Design: Forces every index to be tied to a specific beneficiary query so usefulness can be validated.
  • Execution Plan Validation (Before/After): Requires representative EXPLAIN (ANALYZE, BUFFERS) evidence to confirm plan changes and real-row behavior.
  • Write- and Migration-Safe Guardrails: Calculates write amplification, mandates online build strategy for large tables, and blocks unsafe pagination patterns on big datasets.

Quick Start

Ask for an indexing-query-optimization plan that names the target SQL query, lists its predicates and ORDER BY, and proposes only the minimal composite/covering indexes validated by EXPLAIN (ANALYZE, BUFFERS) before and after.

Dependency Matrix

Required Modules

None required

Components

references

💻 Claude Code Installation

Recommended: Let Claude install automatically. Simply copy and paste the text below to Claude Code.

Please help me install this Skill:
Name: indexing-query-optimization
Download link: https://github.com/machenjie/rd-skills/archive/main.zip#indexing-query-optimization

Please download this .zip file, extract it, and install it in the .claude/skills/ directory.
View Source Repository

Agent Skills Search Helper

Install a tiny helper to your Agent, search and equip skill from 471,000+ vetted skills library on demand.