Welcome to Portal

?Unknown\pull-down

Welcome to Zoho Cares

Bienvenido a Soporte de Zoho

Search our knowledge base, ask the community or submit a request.

Import data from PostgreSQL




You can import data from the PostgreSQL database into Zoho DataPrep using Zoho Databridge. Click here to know about Zoho Databridge.

Before looking into how to import data, let's take a look at the pre-requisites to connect to the PostgreSQL database. 

Prerequisites for PostgreSQL

Please ensure the following conditions are met before proceeding with connecting to your PostgreSQL.

1. Provide database read permissions to the Zoho DataPrep server.

2. Ensure you have the correct login credentials for your database. As a best practice, try connecting to your target database from the Zoho DataPrep server, using the native database management software available for the respective database.

Enable remote connections

Follow the steps below to enable remote connections:

  • Open the file pg_hba.conf found under the PostgreSQL_Home/data/folder. (<PostgreSQL_Home> refers to the directory where PostgreSQL database is installed.)
  • Add the following line, and save the file.

host all all <IP address> trust

Replace <IP address> with the IP address of the Zoho DataPrep server. The IP address must be mentioned along with the subnet mask. For example: 192.168.1.1/24.  

  • Open the file postgresql.conf found under the same <PostgreSQL_Home>/data/ folder. 
  • Find the key listen_address = and add the IP address of the Zoho DataPrep server.

listen_address = '<IP address>'

Replace <IP address> with the IP address of the Zoho DataPrep server. For example: 192.168.1.1.

To import data from PostgreSQL

1. Open an existing pipeline or create a pipeline from the Home Page, Pipelines tab or Workspaces tab and click the Add data option.
InfoInfo: You can also click the Import data  icon at the top of the pipeline builder to bring data from multiple sources into the pipeline.


2. In the next screen, choose the required database or click the Databases category from the left pane. 



3. Select New connection from the Connection drop down. If you have existing connections, you can choose the required connection from the Connection drop down. 

4. Give your connection a name under the Connection name section.

5. Zoho Databridge is a tool that facilitates importing data from local databases. Databridge is mandatory to import data from any local database.
Notes
Note: If this is the first time you are downloading Zoho Databridge, see how to install it here.



6. Once you have installed Databridge on your machine, select your Databridge from the Databridge drop-down. 
Notes
Note: Select the Databridge which is installed in the same network as the database you want to import the data from.

7. Select PostgreSQL in the Database type drop down and enter the Database server host name and Port number.

8. Enter your Database name and provide the username and password if authentication is required.



9. Save your database configuration and connect to the database using Connect.
Notes
Note: The connection configuration will be automatically saved for importing from the database in the future. Credentials are securely encrypted and stored.

10. Select the tables that need to be imported. 




11. You can also use alternatively a SQL query to import data. 
Warning
The incremental fetch option is not available when the data is imported using a query from databases. Click here to know more about incremental fetch from local database.


12. Click the Import button.

13Once you are done creating your data flow and applying necessary transforms in your stages, you can right-click a stage and add a destination to complete your data flow.
Notes
Note:  After adding a destination to the pipeline, you can try executing your pipeline using a manual run at first. Once you make sure manual run works, you can then set up schedule to automate the pipeline. Learn about the different types of runs here.
While configuring the Schedule, Backfill, Manual reload, Webhooks, or Zoho Flow, the import configuration needs to be mandatorily setup for all the sources. Without setting up the import configuration, the run cannot be saved. Click here to know more about how to set up import configuration.

14. After configuring a run, a pipeline job will be created at the run time. You can view the status of a job with the granular details in the Job summary. Click here to know more about the job summary.

To edit the PostgreSQL connection

DataPrep saves your data connections to avoid the hassle of keying in the credentials every time you need to connect to a data source or destination. You can always edit the saved data connection and update them with new parameters or credentials using the Edit connection option. 

1. While creating a new dataset, click Saved data connections from the left pane in the Choose a data source section. 



2. You can manage your saved data connections right from the data import screen. Click the ellipsis (3 dots) icon to share, edit, view the connection overview, or remove the connection. 



3. Click the Edit connection option to update the saved connection with new parameters or credentials.





Helpful?00
Updated: 27 days ago
Share :
  • Redefine the way you work
    with Zoho Workplace

  • Zoho DataPrep Personalized Demo

    If you'd like a personalized walk-through of our data preparation tool, please request a demo and we'll be happy to show you how to get the best out of Zoho DataPrep.

    Zoho CRM Training