Skip to content
Agent Orchestration
Skill

/sql-review

Review SQL and ORM queries for correctness, safety, and performance before they ship.

BOOST
From plugin
loopkit
75553 skills1 agent4 commands2 MCP
Install
$ npx -y skills add Archive228/loopkit --skill sql-review --agent claude-code

How it fires

How this skill gets triggered: by you, by Claude, or both.

  • Fires itselfAuto-invocation. Claude auto-loads it when your prompt matches the work.Auto-invocation is when the right skill fires by itself at the right moment, driven by a FLOW.md router and a hook, instead of you invoking it by name. It is the difference between a skill being installed and a skill actually getting used.Read the full definition →
  • You can call itInvoke it directly when you want it.
  • Slash command/sql-review

Context preview

The summary Claude sees to decide when to auto-load this skill.

Review SQL and ORM queries for correctness, safety, and performance before they ship.

SKILL.md

sql-review.SKILL.md
name: sql-review
description: Review SQL and ORM queries for correctness, safety, and performance before they ship.
when_to_use: new query, a migration, an N+1 suspicion, a slow endpoint

SQL Review

  • **Injection** — parameterized, always. No string interpolation into SQL.
  • **N+1** — a query inside a loop? Replace with a join or a batched IN.
  • **Missing index** — does the WHERE/JOIN/ORDER BY hit an indexed column? If not, the table scan will surface at scale.
  • **Unbounded** — SELECT with no LIMIT on a growing table; a JOIN that fans out rows.
  • **Transactions** — multi-write operations wrapped so a partial failure can't corrupt state.
  • **Migrations** — reversible (up AND down), and safe on a live table (no blocking lock on a hot table at peak).

Output: each issue with the line and the rewrite. Show the EXPLAIN if performance is the concern.

Ships withloopkit

33 battle-tested skills + minimal .claude harness for any coding agent (Claude Code, Cursor, Codex, Gemini CLI).

Get the whole plugin

Other skills on loopkit.