Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Be one of the first to start using Fabric Databases. View on-demand sessions with database experts and the Microsoft product team to learn just how easy it is to get started. Watch now

Reply
fabiomanniti
Helper III
Helper III

Import data from PostgreSQL

Hello, I have my Data on a remote PostreSQL and I'm trying to get them but with no success.

I've tried two ways:
1.

GET DATA -> PostgreSQL Database 

Server: 34.xx.xxx.xxx

Database: myDb

Then I put my username and password and I get this error message

Details: "An error happened while reading data from the provider: 'The remote certificate is invalid according to the validation procedure.'"

 

2.

GET Data ->ODBC

Data source name: None

Connection String: Driver={PostgreSQL ANSI};Server=34.xx.xxx.xxx;Port=5432;Database=myDB

Then I put my credential and I get this error message

Details: "ODBC: ERROR [08001] FATAL: no pg_hba.conf entry for host "10.100.0.1", user "myUser", database "myDB", SSL off"

 

Since it is a remote db I cannot see pg_hba.conf file.

Can anyone suggest a solution?

Thank you

1 ACCEPTED SOLUTION

 I solved this using ODBC

I had to create a ODBC Connector but I also had to enable SSL.

The best way is throug ODBC Administrator (search on windows) so you can make a test to the connection. Otherwise the script is

 

database=xxxx;driver={PostgreSQL Unicode(x64)};port=5432;server=34.xxxxxx;sslmode=require;

 

This worked for me

View solution in original post

4 REPLIES 4
Anonymous
Not applicable

Hi @fabiomanniti 

I'm not sure about connecting to this database from Tableau or Datagrip ,because I don't have the test environment to restore your scenario. Most customers will choose the ODBC connector if they fail to connect to the PostgreSQL database using the PostgreSQL DB connector . Maybe you can talk to the person who manages the database to see if it's a configuration file problem.

 

Best Regard

Community Support Team _ Ailsa Tao

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

 I solved this using ODBC

I had to create a ODBC Connector but I also had to enable SSL.

The best way is throug ODBC Administrator (search on windows) so you can make a test to the connection. Otherwise the script is

 

database=xxxx;driver={PostgreSQL Unicode(x64)};port=5432;server=34.xxxxxx;sslmode=require;

 

This worked for me

Anonymous
Not applicable

Hi @fabiomanniti 

Is your database in the cloud ? If your database is on the cloud, you must also configure remote connections. You must do this by editing the pga_hba.conf file and the postgresql.conf file.

Ailsamsft_0-1643004651104.png

Ailsamsft_1-1643004651109.png

I searched a document about how to connect to Power BI from PostgreSQL , you can refer to it .

https://hevodata.com/learn/connect-postgresql-to-power-bi/

 

Best Regard

Community Support Team _ Ailsa Tao

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

@Anonymous 

Thank you but since I don't have access to those files (I'm not the one who manage the Database) I wanted to ask for a doubt:

I tried to connect this database both on Tableau and Datagrip and I didn't have any problem of connection; so, can it be possible that configuration files have nothing to do with this?

Helpful resources

Announcements
Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!

Dec Fabric Community Survey

We want your feedback!

Your insights matter. That’s why we created a quick survey to learn about your experience finding answers to technical questions.

ArunFabCon

Microsoft Fabric Community Conference 2025

Arun Ulag shares exciting details about the Microsoft Fabric Conference 2025, which will be held in Las Vegas, NV.

December 2024

A Year in Review - December 2024

Find out what content was popular in the Fabric community during 2024.