sql-schema-audit
CommunitySQL schema audit: surface index gaps and N+1.
Authormizchi
Version1.0.0
Installs0
System Documentation
What problem does it solve?
Index coverage and N+1 review aids for SQLite/D1 schemas with a sqlc catalog. Surfaces unused indexes (with FK CASCADE awareness so cascade-load-bearing indexes are not flagged), queries that scan tables without index help, and for-loops calling generated SQL fns.
Core Features & Use Cases
- Audit index coverage by walking query plans and labeling scans that lack covering indexes.
- Surface N+1 patterns in code that call sqlc-generated functions inside loops.
- Highlight FK cascade load-bearing indexes to preserve delete latency performance.
Quick Start
Run the index-coverage.mjs and n-plus-one.mjs scripts against your SQLite schema and sqlc catalog to surface index gaps and N+1 patterns.
Dependency Matrix
Required Modules
None requiredComponents
scripts
💻 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: sql-schema-audit Download link: https://github.com/mizchi/skills/archive/main.zip#sql-schema-audit Please download this .zip file, extract it, and install it in the .claude/skills/ directory.
Agent Skills Search Helper
Install a tiny helper to your Agent, search and equip skill from 510,000+ vetted skills library on demand.