> ## Documentation Index
> Fetch the complete documentation index at: https://docs.delphina.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Warehouse Connections

> Connect your data warehouse so the agent can query your data

A warehouse connection tells Delphina how to reach your data warehouse. Each connection belongs to a workspace and provides read-only access.

Supported: **Snowflake**, **BigQuery**, **Databricks**, **Redshift**, and **PostgreSQL**.

## Adding a connection

1. Go to **Org Admin > Warehouse Connections**.
2. Click **Add Connection**.
3. Choose the workspace, warehouse type, and fill in credentials.
4. Click **Create**.

The first connection for a workspace is automatically set as the default.

## Query timeout

Each connection has an optional **Query Timeout (seconds)** that caps how long any single query may run before it is cancelled. This protects the warehouse from runaway queries during a chat.

* Leave the field blank to use the default of **120 seconds**.
* Allowed range is **1–300 seconds**.
* The timeout is enforced server-side for every supported warehouse (Snowflake, BigQuery, Databricks, Redshift, and PostgreSQL).
* You can change it at any time by editing the connection; the new value applies to chats started afterward.

## Supported warehouses

| Warehouse                                    | Authentication                                                    | Query history |
| -------------------------------------------- | ----------------------------------------------------------------- | ------------- |
| [**Snowflake**](/administration/snowflake)   | Private key, password                                             | Supported     |
| [**BigQuery**](/administration/bigquery)     | Service account JSON, per-user OAuth                              | Supported     |
| [**Databricks**](/administration/databricks) | Service principal, personal access token, optional per-user OAuth | Supported     |
| **Redshift**                                 | IAM role                                                          | Not supported |
| **PostgreSQL**                               | Username/password                                                 | Not supported |

Query history is used during [automated onboarding](/knowledge-agent/onboarding) to identify important tables and metrics.

## Managing connections

* **Default connection** — click the star icon to set which connection the agent uses.
* **Edit** — click the edit icon. Existing credentials are preserved if not changed. Workspace and name cannot be changed after creation.
* **Delete** — click the delete icon. The connection is soft-deleted.

## Configuring source tables

After creating a connection, configure which tables the agent can use:

1. Go to **Context > Sources > Warehouse**.
2. Select a connection.
3. **Tables tab** — browse and select tables for knowledge extraction. Use **Bulk Edit** to paste table names.
4. **Query Users tab** (Snowflake/BigQuery only) — select users whose query patterns inform the agent's knowledge.

## Troubleshooting

| Problem                               | Fix                                                               |
| ------------------------------------- | ----------------------------------------------------------------- |
| Agent can't connect                   | Verify credentials work from another client, then update          |
| "Browse Tables" empty                 | Grant USAGE on the database/schema to the role                    |
| "Show Top Users" empty                | Snowflake/BigQuery only; ensure access to query history views     |
| Connection works but agent ignores it | Set as default for the workspace                                  |
| Queries cancelled too early           | Increase the connection's **Query Timeout (seconds)** (up to 300) |
