pg_search_columns
Search for column names across PostgreSQL user schemas using LIKE patterns with wildcards. Find which tables contain a column without iterating table descriptions.
Instructions
Search for columns by name across all user schemas. Supports SQL LIKE patterns (% matches any substring, _ matches one character). Case-insensitive. Use this instead of iterating pg_describe_table when the user asks 'which tables have X'.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| limit | No | Max rows to return (default 100). | |
| schema | No | Limit to this schema. If omitted, searches all user schemas. | |
| pattern | Yes | LIKE pattern. Use '%' for wildcard: 'user_id', '%email%', 'created_%'. |