Power BI is turning 10! Tune in for a special live episode on July 24 with behind-the-scenes stories, product evolution highlights, and a sneak peek at what’s in store for the future.
Save the dateEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.
Hello,
I am currently facing an issue with connecting a postgres database via the OnPrem Data Gateway.
The MSSQL Databases worked instantly but PostgresSQL constantly throws the error:
Unable to create connection for the following reason: Unable to connect to the data source. Either the data source is inaccessible, a connection timeout occurred, or the data source credentials are invalid. Please verify the data source configuration and contact a data source administrator to troubleshoot this issue.
I ruled out the following things:
Did anyone else encounter such an issue connecting a PostgresSQL DB?
Thanks,
Alex
Solved! Go to Solution.
Hi @Dickbale,
In this scenario i suggest you to raise a support ticket here. so, that they can assit you in addressing the issue you are facing. please follow below link on how to raise a support ticket:
How to create a Fabric and Power BI Support ticket - Power BI | Microsoft Learn
Thanks,
Prashanth Are
Hi,
We are following up once again regarding your query. Could you please confirm if the issue has been resolved through the support ticket with Microsoft?
If the issue has been resolved, we kindly request you to share the resolution or key insights here to help others in the community. If we don’t hear back, we’ll go ahead and close this thread.
Should you need further assistance in the future, we encourage you to reach out via the Microsoft Fabric Community Forum and create a new thread. We’ll be happy to help.
Thank you for your understanding and participation.
Hi @Dickbale ,
Thanks for the detailed breakdown—sounds like you've already ruled out most of the common issues. Here are a few additional things you might want to check:
Gateway Service Account Permissions
Ensure that the On-Premises Data Gateway service account has the necessary permissions to access the PostgreSQL database. Sometimes, even if the connection works manually, the gateway service might be running under a different context.
Connection Encryption Settings
PostgreSQL may require or reject SSL connections depending on its configuration. Try toggling the "Require SSL" option in the gateway connection settings and see if that makes a difference.
Connection String Format
Double-check the format of the connection string in the gateway. Some versions of the gateway are sensitive to parameters like sslmode, timeout, or even the port number format.
Regional Settings or Locale Issues
Rarely, locale or regional settings on the gateway server can affect how credentials or connection strings are parsed—especially with special characters.
Gateway Logs
Check the gateway logs (located in C:\Program Files\On-premises data gateway\GatewayLogs) for more detailed error messages. They might reveal something not shown in the UI.
Try Creating the Connection via Power BI Desktop
As a test, try connecting to the same PostgreSQL DB using Power BI Desktop with the same credentials and settings. If it works there, it might help isolate whether the issue is with the gateway or the connection config.
Let us know if any of these help—or feel free to share the exact connection string format you're using (without credentials), and we can take a closer look.
Hi @Dickbale,
As we haven’t heard back from you, we wanted to kindly follow up to check if the solution provided for your issue worked? or let us know if you need any further assistance here?
Thanks,
Prashanth Are
MS Fabric community support
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly and give Kudos if helped you resolve your query
Hi sorry for the late reply, I was not able to access my work pc.
No sadly this didn 't work, however after doing that and replacing the driver from the gateway with the one from PowerBI I get a new error now:
GW-Fabric: Please install Npgsql version 4.0.17.0 or earlier.
This is odd because I have this driver installed on the pc, and the dll inside of the gateway is this version as well.
Also I can connect to the database with PowerBi from that VM without issue.
In rebooted the service multiple times now but it still doesn't work.
thanks,
Alex
Hi @Dickbale,
In this scenario i suggest you to raise a support ticket here. so, that they can assit you in addressing the issue you are facing. please follow below link on how to raise a support ticket:
How to create a Fabric and Power BI Support ticket - Power BI | Microsoft Learn
Thanks,
Prashanth Are
Hello !
I encounter the same error message when trying to connect to an On prem Data Gateway : "Please install Npgsql version 4.0.17.0 or earlier.".
Did you find the solution to the problem ?
Thank you for your help
As we haven’t heard back from you, we wanted to kindly follow up to check if the solution provided for your issue worked? or let us know if you need any further assistance here?
@lbendlin, thanks for your prompt response
Thanks,
Prashanth Are
MS Fabric community support
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly and give Kudos if helped you resolve your query
@Dickbale, As we haven’t heard back from you, we wanted to kindly follow up to check if the solution provided for your issue worked? or let us know if you need any further assistance here?
@lbendlin, thanks for your prompt response
Thanks,
Prashanth Are
MS Fabric community support
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly and give Kudos if helped you resolve your query
install Power BI Desktop on one of the gateway VMs and try to connect from there. If that works then copy the npgsql files from the Desktop install folder to the Gateway install folder. Restart the gateway service and try again.
This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.
Check out the June 2025 Fabric update to learn about new features.
User | Count |
---|---|
35 | |
16 | |
7 | |
6 | |
3 |
User | Count |
---|---|
48 | |
43 | |
15 | |
7 | |
6 |