George123
George123

Reputation: 77

ODBC connection from Postgres database into Power bi error

Hi I am having issues connecting to my postgres database, I am using this connection string on my 64 bit machine. I have downloaded the updated 64 bit postgres driver.

driver used: database=Travel_Information;driver={PostgreSQL Unicode(x64)};port=5432;server=travel-information.chda0n3dhd8k.eu-west-1.rds.amazonaws.com

Issue when selecting tables to import

Any suggestions?

Upvotes: 2

Views: 6120

Answers (2)

wastek
wastek

Reputation: 111

It is an SSL issue I added sslmode=require at the end of connection string and it succeeded.

I tried before with the original Postgredb connector and various Npgsql versions but it didn't worked.

Although there's still an option to import the certificate from the server to your client To get the SSL cert for the PostgreSQL server you might need to speak to the DBA/sysadmin if you don’t have access. In the configuration folder for the PostgreSQL server there is a postgresql.conf file, search it for ssl settings, there is one with the location of the ssl cert. Note NOT the key file which contains the private key, only the cert file which contains the public key. copy it or its content to the machine running PowerBI and import using that procedure

Upvotes: 1

Miguel de Sousa
Miguel de Sousa

Reputation: 344

In the DSN select "(None)" instead of "dBASE Files" and your connection string should look like this.

database=dbname;driver={PostgreSQL Unicode(x64)};port=5432;server=server.eu-w1.compute.server.com;sslmode=require;

I had to use sslmode=require because I am connecting to a postgresql server instance on heroku server, and it requires it.

Upvotes: 2

Related Questions