PostgreSQL is an open source relational database management system developed by a worldwide team of volunteers.
The PostgreSQL connector allows you to access data from PostgreSQL based databases within Data Studio.In this article:
How to connect to PostgreSQL
This connector uses the PostgreSQL JDBC driver to connect a Data Studio data source to a single PostgreSQL database table.
We've tested Data Studio on the following PostgreSQL versions:
- Sign in to Data Studio.
- In the top left, click then select Data Source.
- Select the PostgreSQL connector
- Configure access to your database using one of the connection options (see below)
- Click AUTHENTICATE
- You will see a list of tables in that database
- Select a table
- Click CONNECT.
You can now access all of the columns in the table as fields in your reports.
To connect with a hostname or IP address, you'll need to provide the following information:
- Hostname or IP address
- Port (Optional)
To connect via a JDBC URL, provide the following connection information:
- JDBC URL
jdbc:postgresql://<hostname or IP address>[:<port>]/<database>
Enable SSL (optional)
Data Studio supports secure (encrypted) connections to the server using the TLS (Transport Layer Security) protocol. TLS is also referred to as SSL (Secure Sockets Layer). To enable a secure connection, check Enable SSL, then provide your SSL client configuration files.
Learn more about PostgreSQL secure connections.
Select the CUSTOM QUERY option to provide a SQL query instead of connecting to a single table. Data Studio uses this custom SQL as an inner select statement for each generated query to the database.
Supported data types
The PostgreSQL connector currently supports the following data types:
- Date/Time (except Intervals)
When Data Studio encounters a column of a non-supported type, it will not create a field for that column.
Learn more about PostgreSQL data types.
If you database is behind a firewall, you will need to open access to the following IP addresses so that Data Studio can access your database:
Limits of the PostgreSQL connector
- You can query a maximum of 150K rows using this connector.
- Column headers (field names) must use ASCII characters only. Non-ASCII characters aren't supported.