Forum Discussion
I am not able to connect Postgre SQL DATABASE
- 9 years ago
Hi Anonymous,
From the error message, the issue is caused by that the connector is not be configured properly. Please refer to this article to configure connector again: Power BI Connectivity to PostgreSQL.
Best Regards,
Qiuyun Yu
Having tried to get this going for a few hours with no success decided to change the approach and use a postgreSQL ODBC driver and it worked straight away.
First get the driver from
https://www.postgresql.org/ftp/odbc/versions/msi/
I downloaded the psqlodbc_09_06_0100-x64.zip and ran psqlodbc_x64.msi
Now click on 'Get Data' in PowerBI and select ODBC. Choose <None> in Data source name (DSN) and click on Advanced Options and enter a connection string which you can find at
https://www.connectionstrings.com/postgresql/
I used something like
Driver={PostgreSQL ANSI(x64)};Server=rds-postgresql-xxxx-warehouse.cftg4xxxxxt.ap-southeast-2.rds.amazonaws.com;Port=5432;Database=myDatabase;
My server is an AWS server. The most important part is the driver name which you can search for in your ODBC settings and you will see a warning icon by the side of the connect string until you get this right.
I have read so much trying to get this all to work. Your suggestion of bypassing all the GUI crap and just using the connection string and OLDB worked perfectly.
Thank you for taking the time to share your connection string so I could do what should have been a simple process and connect to a remote PostgreSQL database (behind SSL encryption) and access my data.
- npgsql didn't work
- getting remote certificates and adding through MMC didn't work (hostname didn't match)
- even ODBC didn't work for me because of some architecture mis match
Selecting ODBC, None, and using a connection string worked.
GG!, Well Played!! That was fun! Everybody Dance!