describe_table
Inspect PostgreSQL table structure before querying: shows columns, data types, nullability, defaults, primary keys, indexes, and foreign keys.
Instructions
Describe a PostgreSQL table: columns with data types, nullability and defaults, plus primary key, indexes and foreign keys.
Use this before writing a query against an unfamiliar table.
Args: table: Table, view or materialized view name. schema: Schema name. Defaults to the session schema, then 'public'. database: Database name. Defaults to the session database.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| table | Yes | ||
| schema | No | ||
| database | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |