Skip to main content
Glama
jdbc-mcp-guard

jdbc-mcp-guard

by lyb-java

db_search_columns

Search column names across database schemas to find which tables contain a field; uses case-insensitive fuzzy matching and cached results.

Instructions

全库模糊搜索列名(回答「这个字段在哪些表」),带缓存。

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "keyword": "<keyword>"
    },
    "name": "db_search_columns"
  }
}

Input Schema

NameRequiredDescriptionDefault
schemaNoschema/owner(默认取连接配置的 database)
keywordYes列名关键字(模糊匹配,不区分大小写)
connectionNo连接名,默认 default

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.2.0

TDQS

A3.5/5.0
Behavior3/5

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

工具没有 annotations,描述必须承担全部行为说明责任;它补充了「带缓存」这一非结构化行为特征,属于有价值的额外信息。但未说明是否为只读、结果数量上限、搜索范围是否限于 connection 指定的库,以及返回结果的粒度(表名列表还是表+列),行为信息仍明显不足。

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?

单句主体加上一个括号补充,共约二十字,语义密集、零冗余,且核心范围(全库、列名)前置,可读性极高。

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

Completeness3/5

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

工具本身有三个参数且无输出 schema,描述对「返回什么」完全没有交代,包括匹配数量、结果结构、跨 schema 的行为,agent 难以预判调用结果。对这样一个搜索类工具,至少应说明返回的是表名与列名的对应关系。

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

Parameters3/5

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

schema 描述覆盖率为 100%,三个参数(keyword、schema、connection)的含义与默认值均已由 schema 完整说明。描述未在 schema 之上补充任何参数语义,按规则基线为 3。

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

Purpose4/5

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

明确说明了动词(模糊搜索)、目标资源(列名)和范围(全库),并用括号给出它回答的具体问题(「这个字段在哪些表」),把 db_search_columns 与 db_schema、db_query 明确区分开。唯一不足是没有点名兄弟工具作为对比。

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

Usage Guidelines3/5

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

括号中的问题描述隐含了使用场景(查找字段所在表),但没有明确说明何时应改用 db_schema 或 db_query,也没有列出使用前置条件或排除情形。指引只能靠推断。

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