> For the complete documentation index, see [llms.txt](https://upsolver.gitbook.io/content/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://upsolver.gitbook.io/content/reference-1/sql-commands/connections/create-connection/amazon-redshift.md).

# Amazon Redshift

An Amazon Redshift connection is used to support exporting/loading data from your Upsolver tables into Redshift.&#x20;

## Syntax

```sql
CREATE REDSHIFT CONNECTION <connection_identifier> 
    CONNECTION_STRING = '<connection_string>' 
    USER_NAME = '<user_name>'
    PASSWORD = '<password>' 
    [ MAX_CONCURRENT_CONNECTIONS = <integer> ]
    [ COMMENT = '<comment>' ]
```

#### Jump to

* [`CONNECTION_STRING`](#connection_string-editable)
* [`USER_NAME`](#user_name-editable-with-password)
* [`PASSWORD`](#password-editable-with-user_name)
* [`MAX_CONCURRENT_CONNECTIONS`](#max_concurrent_connections-editable)
* [`COMMENT`](#comment-editable)

## Connection options

#### `CONNECTION_STRING` — editable

Type: `text`

The connection string to use when connecting to the database. The string can be copied directly from Redshift.&#x20;

An IAM can be added to the connection string, allowing you to connect to Redshift without using a password. More information regarding IAM can be found [here](https://docs.aws.amazon.com/redshift/latest/mgmt/generating-iam-credentials-configure-jdbc-odbc.html).

#### `USER_NAME` — editable

Type: `text`

The user to authenticate to the DB with.

#### `PASSWORD` — editable

Type: `text`

The password to use for authentication. Optional when using IAM-based authentication (please see `CONNECTION_STRING)`.

#### `MAX_CONCURRENT_CONNECTIONS` — editable

Type: `integer`

(Optional) The maximum number of concurrent connections to the DB.&#x20;

Limiting this may reduce the load on the database but could result in longer data latency.

#### `COMMENT` — editable

Type: `text`

(Optional) A description or comment regarding this connection.

## Minimum example

```sql
CREATE REDSHIFT CONNECTION redshift_connection
    CONNECTION_STRING = 'jdbc:redshift://<host_name>:5439/<database_name>'
    USER_NAME = 'your username'
    PASSWORD = 'your password';
```

## Full example

```sql
CREATE REDSHIFT CONNECTION redshift_connection
    CONNECTION_STRING = 'jdbc:redshift://<host_name>:5439/<database_name>'
    USER_NAME = 'your username'
    PASSWORD = 'your password'
    MAX_CONCURRENT_CONNECTIONS = 10
    COMMENT = 'My new Redshift connection';
```


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://upsolver.gitbook.io/content/reference-1/sql-commands/connections/create-connection/amazon-redshift.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
