Amazon Redshift
This guide walks you through connecting Amazon Redshift to Solid so you can get insights into your data lineage, usage, and quality.
Overview
Solid requires access to:
- The schema of your Redshift databases
- Query history from system views (
STL_QUERY,STL_QUERYTEXT) - Read-only grants on your data — required for Solid's Text2SQL engine to generate and validate SQL
Note: You will need superuser access (or an equivalent admin role) to create the Solid user and role.
You have two options for connecting Redshift to Solid:
| Option | Best For | What You'll Do |
|---|---|---|
| Automatic Pull (Recommended) | Ongoing use and continuous monitoring | Create a service user that runs automatically |
| Manual Pull | Quick proof of concept or one-time setup | Export data manually and upload it |
What Is Collected
| Category | What | Why |
|---|---|---|
| Metadata | Table/column definitions, data types, constraints | To build the data catalog |
| Query History | Query text, executing user, timestamps, duration | To learn usage patterns and seed benchmarks |
| Table Usage | Row insert/update/delete counts per table | To surface active tables and detect stale data |
| Data Profiling | Sampled column values (via granted SELECT) | Required for Text2SQL generation/validation, and to improve SQL filter accuracy |
Automatic Pull (Recommended)
Best for: Production use with continuous monitoring and updates.
Step 1: Create the Solid User and Role
Run this script while connected as a superuser (or equivalent admin role):
-- Create a dedicated user for Solid
CREATE USER solid_data PASSWORD '{strong_password}';
-- Create a role scoped to metadata and read access
CREATE ROLE solid_data_role;
-- Grant usage on the schemas you want Solid to monitor
GRANT USAGE ON SCHEMA {schema_name} TO ROLE solid_data_role;
-- Grant read access to tables and views in those schemas — required for
-- Solid's Text2SQL engine to generate and validate SQL
GRANT SELECT ON ALL TABLES IN SCHEMA {schema_name} TO ROLE solid_data_role;
-- Allow visibility into system catalog and query history views
GRANT SELECT ON ALL TABLES IN SCHEMA pg_catalog TO ROLE solid_data_role;
-- Attach the role to the Solid user
GRANT ROLE solid_data_role TO solid_data;Repeat the GRANT USAGE / GRANT SELECT pair for every schema you want Solid to monitor.
Step 2: Note Your Connection Details
You'll need:
- Cluster endpoint (or Redshift Serverless workgroup endpoint)
- Port (default
5439) - Database name
- Username:
solid_data - Password: the password you set above
Step 3: Configure Solid
- Log into the Solid platform
- Navigate to Settings → Integrations → Redshift
- Enter your connection details and credentials
- Click Test Connection
- Select which schemas you want Solid to monitor
- Click Save
Solid will begin syncing your Redshift metadata and query history.
Manual Pull
Best for: Testing Solid or if you can't grant direct database access yet.
Steps
- Run the queries below in the Redshift Query Editor
- Export each result as a CSV file
- Upload to the Solid Azure Storage container
Metadata
SELECT
c.table_schema,
c.table_name,
c.column_name,
c.ordinal_position,
c.data_type,
c.is_nullable,
c.column_default
FROM information_schema.columns c
WHERE c.table_schema IN ({schema_list})
ORDER BY c.table_schema, c.table_name, c.ordinal_position;Query History
SELECT
q.query,
q.userid,
q.starttime,
q.endtime,
t.text AS query_text
FROM stl_query q
JOIN stl_querytext t ON q.query = t.query
WHERE q.starttime > '{last_collect_time}'
ORDER BY q.starttime DESC;Permissions Needed
| Permission/Grant | Purpose |
|---|---|
solid_data_role (role) | Dedicated role scoping Solid's metadata and read access |
GRANT USAGE ON SCHEMA {schema_name} | Lets Solid see objects within a monitored schema |
GRANT SELECT ON ALL TABLES IN SCHEMA {schema_name} | Read access to tables/views — required for Solid's Text2SQL engine to generate and validate SQL |
GRANT SELECT ON ALL TABLES IN SCHEMA pg_catalog | Visibility into system catalog and query history views |
GRANT ROLE solid_data_role TO solid_data | Attaches the role's permissions to the Solid service user |
Troubleshooting
Connection Issues
- Verify the cluster/workgroup endpoint and port are correct and reachable from Solid's network
- Confirm the user isn't locked and the password hasn't expired
- Check your security group / VPC rules allow inbound connections from Solid's static IP addresses
Permission Issues
- Check the role's grants:
SELECT * FROM svv_table_privileges WHERE grantee = 'solid_data_role'; - Confirm
GRANT USAGE ON SCHEMAwas run for every schema you want monitored —SELECTgrants alone aren't sufficient without schema-levelUSAGE
Security Notes
- The service user has read-only access — no
INSERT,UPDATE,DELETE, or DDL privileges - Use a strong, unique password and rotate it per your organization's policy
- Restrict Redshift's port (
5439) to Solid's static IP addresses via your security group rules - Scope grants only to the schemas Solid needs to monitor
Updated 8 days ago
Did this page help you?
