Diagnose Seq Scans banner
civitai civitai

Diagnose Seq Scans

Development community

Description

--- description: Remedy high seq scans on a table argument-hint: "[table name]" --- Your goal is to diagnose why there are high volumes of seq scans in a postgres database. You'll be using the postgres MCP to interact with a read replica of a postgres database. ## Workflow 1. To prepare, use context7 to review documentation about views, joins, indexes, seq scans, and available diagnostic and stat tables/queries in postgres 17. 2. Review the structure of the target table: $ARGUMENTS 3. Review e

Installation

Installs to ~/.claude/commands/civitai-civitai-diagnose-seq-scans.md

Terminal
mkdir -p ~/.claude/commands && curl -fsSL https://raw.githubusercontent.com/civitai/civitai/HEAD/.claude/commands/diagnose-seq-scans.md -o ~/.claude/commands/civitai-civitai-diagnose-seq-scans.md

Restart Claude Code, or start a new session, for it to be picked up.

Full documentation available on GitHub

View Source Repository