Skip to main content
Glama
S-CurveLabs

io.github.S-CurveLabs/sqlglass

Official
by S-CurveLabs

rename_in_library

Rename a database table or column across all saved queries, updating references in SQL while preserving strings and comments. Preview changes with dry run, then apply when ready.

Instructions

Follow a database rename through every saved query, token-aware (strings and comments untouched). kind='table': old='dbo.Vendor', new='dbo.Supplier' kind='column': table='dbo.Vendor', old='Name', new='VendorName' (alias-qualified references, and bare ones in single-table queries; ambiguous bare references are reported, not changed). dry_run defaults to TRUE: review the diff, then call again with dry_run=false.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
newYes
oldYes
kindYes
tableNo
dry_runNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.7/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description carries the full behavioral burden and does so thoroughly: it discloses token-aware rewriting, that strings/comments are untouched, that alias-qualified and bare references are handled, and that ambiguous bare references are reported rather than changed. It also exposes the dry-run safety behavior.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is compact and front-loaded: the essential behavior comes first, followed by distilled examples and the dry-run workflow. Every line earns its place and there is no filler or repetition.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a mutation tool with no output schema and minimal param metadata, the description covers invocation, edge cases, and the dry-run workflow well. The main gap is that table is marked optional in the schema while the example implies it is required for kind='column'; the description does not explicitly settle that constraint.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, but the description compensates with concrete examples for kind='table' and kind='column', showing how old, new, and table relate. It also explains dry_run's meaning and default. All five parameters gain practical semantics beyond the bare schema titles.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The opening sentence states a specific operation: following a database rename through every saved query with token-aware rewriting. The table/column examples clarify exactly what resource is being acted on, and the sibling list confirms this is the only library-rewrite tool, so there is no ambiguity.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides a clear workflow: dry_run defaults to true so the agent can review the diff, then invoke again with dry_run=false. It does not explicitly name alternative tools or state when not to use this tool, but the examples and the unique rename purpose set the context well.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.