Connecting to a PostgreSQL Database
Connecting to a PostgreSQL database in Livedocs allows you to access live data directly within your documents for analysis and visualization. By setting up a database connection, you can work seamlessly with enterprise-grade datasets without needing to import files manually.
To connect to a PostgreSQL database, follow these steps:
- Navigate to the Data tab in the Livedocs workspace.
- Locate the Databases section and click Add database connector.
- In the Connect database dialog, choose your preferred method for providing connection details:
- Individual Fields (default): Fill out the required fields:
- Name: A label to identify the database connection in Livedocs.
- Host: The hostname or IP address of your PostgreSQL server.
- Port: The port number used by your PostgreSQL server (default is 5432).
- Database name: The name of the database you want to connect to.
- Username: The username with access to the database.
- Password: The password associated with the username.
- Connection URL: If you prefer to use a connection string, check the Connect using URL box at the bottom of the dialog. This will replace the individual fields with a single Connection URL input field. Enter your PostgreSQL connection string directly into this field.
- Individual Fields (default): Fill out the required fields:
- Click Connect to database to establish the connection to the PostgreSQL database.
Once connected, the database will appear in the list view of the Databases section. The list view provides essential details about your connection, including its name, the database it is connecting to, and the uploader, making it easy to manage multiple data sources.
If you no longer need a database connection, click its accompanying menu (three vertical dots) and then click Delete.
With your PostgreSQL database successfully connected, you can now query its data and use it as a source for your Livedocs documents. This setup enables real-time data exploration and analysis, empowering you to build dynamic and data-rich documents seamlessly.