analyze_table_relationships
Analyze foreign key relationships to build a dependency graph showing orphan tables, cascading delete chains, hub entities, and circular dependencies for schema design and migration planning.
Instructions
Analyze foreign key relationships between tables. Builds a dependency graph showing entity connectivity, orphan tables (no FKs), cascading delete chains (shown at full depth), hub entities (tables with 5+ FK connections), and circular FK dependencies. Useful for understanding schema design, planning migrations, and impact analysis.
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": "analyze_table_relationships"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| schema | No | Database schema to analyze (default: public) | public |
| timeout_ms | No | Connection timeout in milliseconds (default: 30000). Increase for slow or remote databases. |