get_all_tables_stats
Retrieve detailed access and maintenance statistics for every PostgreSQL table to analyze usage patterns and identify maintenance needs; optionally include system catalog tables.
Instructions
[Tool Purpose]: Get comprehensive statistics for all tables (including system tables if requested)
[Exact Functionality]:
Show detailed access statistics for all tables in database
Include sequential scans, index scans, and tuple operations
Provide live/dead tuple estimates and maintenance history
Option to include system catalog tables
[Required Use Cases]:
When user requests "all tables stats", "complete table statistics", etc.
When analyzing overall table usage patterns
When investigating table maintenance needs across the database
When getting comprehensive database activity overview
[Strictly Prohibited Use Cases]:
Requests for table maintenance operations (VACUUM, ANALYZE)
Requests for statistics reset or modification
Requests for table optimization actions
Tool call template
This tool declares no required parameters. Add optional parameters from the input schema as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {},
"name": "get_all_tables_stats"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| database_name | No | Database name to analyze (uses default database if omitted) | |
| include_system | No | Include system tables in results (default: False) |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |