Table usage
get_table_usageIdentifies all foreign keys, views, procedures, and functions that reference a table, enabling impact analysis before schema changes.
Instructions
Lists everything that references one table: foreign keys to and from it, and the views, procedures and functions whose code uses it. Use it for impact analysis before changing a table; for the dependency graph of the whole database use get_dependency_graph. sql_module_usage is null when the login cannot read dependencies, and 'visibility' says when the list may be incomplete.
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": {
"database": "<database>",
"table": "<table>"
},
"name": "get_table_usage"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| table | Yes | Table name, bare, with no schema prefix. | |
| schema | No | Table schema. Empty searches every schema. Example: 'Feeder' | |
| database | Yes | Name of the database as registered in the configuration. |