---
title: "Advanced PostgreSQL Connection"
slug: "advanced-postgres-connection"
updated: 2025-05-12T21:44:46Z
published: 2025-05-12T21:44:46Z
---

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

# Advanced PostgreSQL Connection

## Overview

Creating and using a custom connection string to integrate with PostgreSQL allows specific parameters to be set to ensure a successful connection. The following article will show how the connection string should be configured to allow SSL.

The platform currently uses **Npgsql v5.0.7** to connect with PostgreSQL. By default, Npgsql will validate the server's certificate; this will fail if the certificate is self-signed. Instruct Npgsql to ignore this by specifying **Trust Server Certificate=true** in the connection string.

To precisely control how the server's certificate is validated, register **UserCertificateValidationCallback** on**NpgsqlConnection**.

This document is only meant to be used for making external integrations for PostgreSQL databases. Decisions does support PostgreSQL for the application server. Learn more in the [Installation Guide](https://documentation.decisions.com/docs/installation-guide).

### Additional Resources

- [Npgsql Connection String Parameters](https://www.npgsql.org/doc/connection-string-parameters.html?q=trust)
- [Npgsql Connection String Builder](https://www.npgsql.org/doc/api/Npgsql.NpgsqlConnectionStringBuilder.html)

---

## Setup

1. In the Folder Tree, navigate to**System > Integrations > Databases**.
2. Select **Create Connection**in the Top Bar.
3. In the **Database Integration** window, give the connection a **Name**, select **POSTGRES**as the **Database Type**.
4. Set **Custom Connection String** to **True**.
5. Edit the below example string parameters to match the Npgsql properties and place the string into the **Connection String**text box.

```actionscript
Host=hostname;Database=databasename;Port=5432;Integrated Security=False;Username=postgres;Password=xxx;TrustServerCertificate=True
```

![](https://cdn.document360.io/6ef8bcc1-6489-4486-9ad1-83acff7e5df0/Images/Documentation/2024-06-20_14h50_47.png)

---

For further information on Integrations, visit the [Decisions Forum](https://community.decisions.com/categories/Integrations).
