PostgreSQL

Connect and extract metadata from PostgreSQL 9.6, 10, 11, 12, 13, 14, 15, and 16+.

Connection Parameters

ParameterDescriptionRequiredExample
HostDatabase server addressYeslocalhost or db.example.com
PortDatabase portYes5432 (default)
DatabaseDatabase nameYesproduction_db
UsernameDatabase userYesreadonly_user
PasswordUser passwordYes********
SSL ModeSSL/TLS encryptionOptionalrequire, verify-full

Required Permissions

We recommend creating a dedicated read-only user for metadata extraction. Run the following SQL commands to grant the necessary permissions:

Grant Permissions
-- Minimum required permissions
GRANT CONNECT ON DATABASE your_database TO readonly_user;
GRANT USAGE ON SCHEMA public TO readonly_user;
GRANT SELECT ON ALL TABLES IN SCHEMA public TO readonly_user;

-- For metadata extraction
GRANT SELECT ON pg_catalog.pg_tables TO readonly_user;
GRANT SELECT ON information_schema.tables TO readonly_user;
GRANT SELECT ON information_schema.columns TO readonly_user;

Special Features

Rich Metadata

Extracts detailed constraints, indexes, triggers, and comments for comprehensive documentation.

Fast Performance

Optimized internal queries ensure rapid metadata retrieval even for large schemas.

Multi-Schema Support

Seamlessly access and document all schemas within a single database connection.

Relationship Mapping

Automatic detection and visualization of foreign key relationships across tables.

Common Issues & Solutions

Connection Refused

Check firewall rules and ensure PostgreSQL accepts remote connections in postgresql.conf and pg_hba.conf.

SSL Certificate Verification Failed

Set SSL mode to 'require' instead of 'verify-full' if using self-signed certs, or provide proper CA certificates.

Cannot See Tables

Ensure the user has USAGE permission on schemas and SELECT permission on the specific tables you want to document.

Schema Visibility

Check your search_path configuration. 3X respects the user's search_path when listing tables.