# PostgreSQL

PostgreSQL is an open-source relational database system known for its reliability and feature robustness. As a development environment in Paradime, PostgreSQL enables dbt™️ development from Paradime's **Code IDE**.

{% hint style="warning" %}
**IP RESTRICTIONS**

Make sure to allow traffic from one of the Paradime IPs in your firewall depending on the data location selected.

👉 See also: [Paradime IP addresses](https://docs.paradime.io/app-help/developers/ip-restrictions).
{% endhint %}

### Setup Instructions

1. Click **Settings** in the top menu bar of the Paradime interface to access **Account Settings**
2. In the left sidebar, click "**Connections**"
3. Click "**Add New**" next to the Code IDE section
4. Select "**PostgreSQL**"
5. In the **Profile Configuration** field, add at least these required parameters. For additional configuration options, see the [Profile Fields Reference](#profile-fields-reference) section.

```yaml
host: analytics-db.company.com                # Database host
port: 5432                                    # Connection port
user: analytics_user                          # Database user
password: ****                                # User password
database: analytics_prod                      # Production database
schema: dbt                                   # Default schema
```

{% hint style="info" %}
After adding the configuration, ensure it's properly formatted using a YAML formatter like [YAML Formatter](https://jsonformatter.org/yaml-formatter).
{% endhint %}

6. Provide a dbt™ **Profile Name** (This should match with the profile name set in your `dbt_project.yml`).
7. In the **Target** field, enter "**dev**". This is the default target your dbt project will use for development work.
8. The "**Schema**" field is pre-configured, but you can change it to specify the schema where dbt will build objects.
9. The "**Threads**" value is pre-configured to 1, but you can adjust this number to specify how many parallel operations your dbt project can run.

***

### Example Profile Configuration

<figure><img src="https://2337193041-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FHET0AD04uHMgdeLAjptq%2Fuploads%2FAxJBZPuvEWIIyRDcQnJ0%2Fimage.png?alt=media&#x26;token=60f5d015-a878-42ae-853f-30076df63aa7" alt=""><figcaption></figcaption></figure>

***

### Profile Fields Reference

<table><thead><tr><th width="163">Field</th><th width="219">Description</th><th width="176">Example</th><th width="155">Default Value</th><th width="121">Required</th></tr></thead><tbody><tr><td>host</td><td>Database server hostname or IP address</td><td><code>db.company.com</code></td><td>None</td><td>✅</td></tr><tr><td>user</td><td>PostgreSQL authentication username</td><td><code>postgres_user</code></td><td>None</td><td>✅</td></tr><tr><td>password</td><td>User authentication password</td><td><code>your_password</code></td><td>None</td><td>✅</td></tr><tr><td>port</td><td>PostgreSQL server port number</td><td><code>5432</code></td><td><code>5432</code></td><td>✅</td></tr><tr><td>dbname</td><td>Name of the target database</td><td><code>analytics</code></td><td>None</td><td>✅</td></tr><tr><td>schema</td><td>Name of the target schema.<br><br>This is configured in the UI "Schema" field</td><td><code>public</code></td><td><code>public</code></td><td>✅</td></tr><tr><td>threads</td><td>Number of concurrent operations. <br><br>This is configured in the UI "Threads" field</td><td><code>4</code></td><td><code>1</code></td><td>✅</td></tr><tr><td>keepalives_idle</td><td>Time in seconds between connection keepalive pings</td><td><code>60</code></td><td><code>0</code></td><td>❌</td></tr><tr><td>connect_timeout</td><td>Seconds to wait for connection establishment</td><td><code>10</code></td><td><code>10</code></td><td>❌</td></tr><tr><td>retries</td><td>Number of times to retry failed connections</td><td><code>3</code></td><td><code>1</code></td><td>❌</td></tr><tr><td>search_path</td><td>Order of schemas Postgres will search through</td><td><code>public , prod</code></td><td><code>$user,public</code></td><td>❌</td></tr><tr><td>role</td><td>PostgreSQL role to assume when executing queries</td><td><code>analytics_role</code></td><td>None</td><td>❌</td></tr><tr><td>sslmode</td><td>Level of SSL connection security</td><td><code>verify-full</code></td><td><code>prefer</code></td><td>❌</td></tr><tr><td>sslcert</td><td>Path to client SSL certificate file</td><td><code>/path/to/cert</code></td><td>None</td><td>❌</td></tr><tr><td>sslkey</td><td>Path to client SSL private key file</td><td><code>/path/to/key</code></td><td>None</td><td>❌</td></tr><tr><td>sslrootcert</td><td>Path to SSL root certificate authority file</td><td><code>/path/to/root.crt</code></td><td>None</td><td>❌</td></tr></tbody></table>


---

# Agent Instructions: 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:

```
GET https://docs.paradime.io/app-help/documentation/settings/connections/development-environment/postgresql.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
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.
