Skip to main content
Glama
ChingEnLin
by ChingEnLin

list_tables

Read-only

List tables, views, and materialized views in a PostgreSQL database with estimated row counts and total size. Filter by schema or database to inspect specific parts of the schema.

Instructions

List tables, views and materialized views in a PostgreSQL database, with estimated row counts and total size.

Args: database: Database name. Defaults to the session database. schema: Optional schema filter. Omit to list every non-system schema.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
schemaNo
databaseNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Behavior4/5

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

Annotations already declare readOnlyHint=true and destructiveHint=false, covering safety. The description adds behavioral context beyond that: it states the tool returns estimated row counts and total size, and clarifies that omitting the schema filter lists every non-system schema. This gives useful behavioral expectations.

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 main purpose is in the first sentence, followed by brief parameter notes. Every sentence adds value, with no fluff or repetition.

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

Completeness5/5

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

The tool is a simple read-only listing operation. Annotations cover safety, an output schema exists so return values are defined, and the description adequately explains scope (tables/views/materialized views) and filtering. There is no missing information that would impede correct invocation.

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?

The input schema has no descriptions, but the description fully explains both parameters: database (defaults to session database) and schema (optional filter, omit for all non-system schemas). This directly compensates for the 0% schema coverage and adds meaningful semantics.

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 description clearly states a specific action (list) with a specific resource (tables, views, materialized views) and adds detail about what is included (estimated row counts and total size). This distinguishes it from sibling tools like list_schemas or list_databases, which have different targets.

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?

The description implies when to use this tool (to list tables/views/materialized views) but provides no explicit guidance on when to prefer it over alternatives, nor does it mention exclusions. For example, it does not say 'use this instead of describe_table'. Usage is implied by the purpose but not explicitly contrasted with siblings.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/ChingEnLin/SQMCPaL'

If you have feedback or need assistance with the MCP directory API, please join our Discord server