Skip to main content
Glama

partition_analysis

List all partitioned tables across schemas or analyze specific table's partitions for details, size, activity, indexes, and maintenance needs.

Instructions

Partition analysis - list all partitioned tables or analyze specific table.

LEVEL: Schema ↔ Table (multi-level tool)

  • table=None (default): Lists all partitioned tables across ALL schemas

  • table='orders': Requires schema - detailed partition analysis for that table

USE FOR: partitions, partition analysis, partition details, partition size, inheritance, "which tables are partitioned?", partition skew detection, empty partition identification. DO NOT USE FOR: non-partitioned table maintenance (use maintenance_analysis), schema structure (use get_schema), index health (use maintenance_analysis).

INCLUDE OPTIONS (only when table is specified):

  • 'all': Everything (default)

  • 'details': Partition details - boundaries, row counts, dead rows

  • 'size': Size distribution - partition sizes, percentages, skew detection

  • 'activity': Partition activity - inserts, updates per partition

  • 'indexes': Partition indexes

  • 'maintenance': Empty partitions, maintenance candidates, default partitions

Examples: partition_analysis() - List all partitioned tables across all schemas partition_analysis(table='events', schema='logs') - Detailed analysis of events table partition_analysis(table='orders', schema='shipment', include='size') - Size distribution

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
tableNoPartitioned table name (omit to list all partitioned tables)
schemaNoSchema name. REQUIRED when table is specified. Use get_schema() to list available schemas.
includeNoWhat to include: 'all', 'details', 'size', 'activity', 'indexes', 'maintenance'all
formatNoOutput format: 'json' or 'markdown'json
urlNoDatabase URL for auto-connection

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Behavior4/5

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

No annotations are provided, so the description carries the full burden. It discloses the two operational modes (list all vs analyze specific) and describes include options. However, it does not explicitly state that the tool is read-only or describe potential resource impact. Given the tool is analytical, this is mostly adequate but could be more explicit about safety.

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 well-structured with clear sections (main description, LEVEL, USE FOR/DO NOT USE FOR, INCLUDE OPTIONS, Examples). It is front-loaded with the main purpose and each sentence adds value. No redundancy or fluff. The examples are helpful and concise.

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?

Given the tool's complexity (multi-level, many include options) and the presence of an output schema, the description is highly complete. It covers all aspects: purpose, when to use (including exclusions), parameter behavior, options, and examples. It also cross-references sibling tools effectively. No gaps are apparent.

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 description adds significant meaning beyond the input schema. For table, it explains the default behavior (list all). For schema, it notes 'REQUIRED when table is specified' and suggests get_schema() for listing schemas. For include, it describes each option. For format, it specifies output types. For url, it mentions auto-connection. This provides rich context for each parameter.

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 'Partition analysis - list all partitioned tables or analyze specific table.' It uses specific verbs 'list' and 'analyze' with a clear resource (partitioned tables). It distinguishes from siblings by explicitly listing DO NOT USE FOR alternatives like maintenance_analysis and get_schema.

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

Usage Guidelines5/5

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

The description provides explicit 'USE FOR' and 'DO NOT USE FOR' sections listing use cases and alternatives. It also explains the multi-level behavior (table=None vs table specified) and gives examples for different scenarios. This makes it clear when to use this tool versus siblings like maintenance_analysis or get_schema.

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/snss10/DBeast'

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