Skip to content
Back to skills

Run Scripts

ASecurity

Running a multi-statement SQL script through the sql-server server as one transaction, dry run before commit. Use when a change needs several statements to land together on a sql-server registration, or a script run rolled back. Not for one statement: the write-rows skill.

  • 34 stars
  • 0 votes
  • 0 copies
  • 0 views
  • Added December 4, 2026
ai-agentsgosqldatabase

Security analysis

A100/100

Scanned December 4, 2026

npx -y skills add melodic-software/claude-code-plugins --skill run-scripts --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Run Scripts?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Run Scripts
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/melodic-software-run-scripts/badge)](https://www.skillsdirectory.com/skills/melodic-software-run-scripts)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: run-scripts
description: "Running a multi-statement SQL script through the sql-server server as one transaction, dry run before commit. Use when a change needs several statements to land together on a sql-server registration, or a script run rolled back. Not for one statement: the write-rows skill."
disable-model-invocation: false
---

# Run scripts

## First, check the tool list

Scripts run only through `script_dry_run` and `script_commit`. When those two tools are not in
your tool list, this registration has no script tier: tell the person the script cannot run
through it, and stop. Never emulate the script with `write` calls. The tier exists so a script
lands as one transaction, and each `write` call commits on its own, so a failure partway through
leaves the earlier statements applied.

## The contract

- Pass the script text exactly as written. Never edit, reorder, split or reformat it to suit the
  tool; when it cannot run as written, tell the person what would need to change and let them
  change it.
- Dry run first, with `script_dry_run`. It executes every statement inside a transaction that
  rolls back, so on a shared environment the script still runs against live data while it runs.
  Show the person the script, the environment and the database, and have them approve the dry run
  as well as the commit.
- Show the person the dry run's result before any commit. `script_commit` ties a commit to its
  matching dry run; take how it does that from the tool's own description, and every argument
  name from its input schema.
- When a commit's effect differs from its dry run, the commit rolls back. The next step is a new
  dry run shown to the person, never a second commit.
- Never retry a commit on its own, after an error, a timeout or a rollback. Read the result's
  message and `next` step, learn the state with a read, and go back to the person.

## Next

- The script committed and the person wants the result checked: the query-safely skill.
- The change turns out to be a single statement: the write-rows skill.

## Related

- No sql-server registration is available, or a call reports that the config is invalid: the setup skill.

## Gotchas

- Many script runs end rolled back, because every dry run does. A rolled-back dry run is the
  dry run working; read its result before treating it as a failed script.
- A script split into `write` calls loses its single transaction. When the script tools are
  missing, the answer is to stop, not to split.

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

View all in ai-agents →

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.