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

Earn the coveted Fabric Analytics Engineer certification. 100% off your exam for a limited time only!

Reply
georgehalford22
Frequent Visitor

Unable to connect to PostgreSQL database on 64 bit windows machine using ODBC connection

Error message: DataSource.Error: ODBC: ERROR [HY000] Error while executing the query
Details:
DataSourceKind=Odbc
DataSourcePath=database=Travel_Information;driver={PostgreSQL Unicode(x64)};port=5432;server=travel-information.chda0n3dhd8k.eu-west-1.rds.amazonaws.com
OdbcErrors=Table

 

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

 

Any suggestions?

8 REPLIES 8
jmleguedard
New Member

Same error here.

And when I try to connect directly via "Get Data>Database>PostgreSQL database connection", I get this error.

Does anybody have an update about this ODBC issue?

Anonymous
Not applicable

Was this issue ever resolved? I'm attempting to connect via ODBC and as above, I can see the tables, but if I then preview the data I get the error 

 

DataSource.Error: ODBC: ERROR [HY000] Error while executing the query
Details:
DataSourceKind=Odbc
DataSourcePath=database=**;driver={PostgreSQL ANSI(x64)};port=****;server=***.***.***.***
OdbcErrors=Table

 

and the data doesn't load.

Replacing the 32-bit version of Microsoft 365 by the 64-bit version solved that issue.

v-qiuyu-msft
Community Support
Community Support

Hi @georgehalford22,

 

In Power BI desktop, there is a built-in PostgreSQL data source for us to get data, please try this instead. 

 

q6.PNG

 

By the way, is there any specific reason you need to use ODBC connect to PostgreSQL? 

 

Best Regards,
Qiuyun Yu 

Community Support Team _ Qiuyun Yu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

For both ODBC and through the normal connector on Power Bi I am unable to connect, the error messages are extremely vague.

Hi @georgehalford22,

 

Would you please share the error message when you get data from PostgreSQL in Power BI desktop? 

 

Also please enable the desktop trace log and share the log files with us. You can upload log files to your OneDrive or Dropbox then share the link here. 

 

Best Regards,
Qiuyun Yu 

Community Support Team _ Qiuyun Yu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Is this issue solved?

I am facing the same problem while i try to connect PowerBI desktop to my PostgreSQL server.

While using ODBC:
DataSource.Error: ODBC: ERROR [HY000] Error while executing the query
Details:
    DataSourceKind=Odbc
    DataSourcePath=dsn=idempiere
    OdbcErrors=Table

 
While using a Get Data>Databse>PostgreSQL database connection:
This connection requires one or more additional components to be installed before it can be used
With a link to: https://github.com/npgsql/Npgsql/releases

I installed the driver, restarted my computer but still get the same error message.

My question is, if its able to see the tables on my database while using the ODBC connection why is it unable to get to the data?

Anyhelp would be appreciated.

Regards
3

I also got the same error trying to connect to PostgreSQL via ODBC (using Power BI Desktop September release).

 

The error I see in trace logs is:

 

DataMashup.Trace Error: 24579 : {"Start":"2017-09-29T06:34:57.5573355Z","Action":"Engine/IO/Odbc/Connection/GetInfo32","HostProcessId":"6700","InfoType":"SQL_CONVERT_GUID","Exception":"Exception:\r\nExceptionType: Microsoft.Mashup.Engine1.Library.Odbc.Interop.OdbcException, Microsoft.MashupEngine, Version=1.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35\r\nMessage: ERROR [HYC00] Unrecognized key passed to PGAPI_GetInfo.\r\nStackTrace:\n   at Microsoft.Mashup.Engine1.Library.Odbc.OdbcCachingService.OdbcCachingConnection.OdbcFunctionCaching.GetResult[Output](UInt16 input, Func`3 function)\r\n   at Microsoft.Mashup.Engine1.Library.Odbc.OdbcTracingService.OdbcTracingConnection.<>c__DisplayClass7.<GetInfoInt32>b__6(IHostTrace trace)\r\n   at Microsoft.Mashup.Engine1.Library.Common.Tracer.Trace[T](String method, Func`2 func, Boolean hasNoPii)\r\n\r\n\r\n","ProductVersion":"2.50.4859.502 (PBIDesktop)","ActivityId":"1ff501af-0513-4e55-bbfd-e3ba6af3137e","Process":"Microsoft.Mashup.Container.NetFX40","Pid":8836,"Tid":1,"Duration":"00:00:00.0037171"}

 

 

Helpful resources

Announcements
April AMA free

Microsoft Fabric AMA Livestream

Join us Tuesday, April 09, 9:00 – 10:00 AM PST for a live, expert-led Q&A session on all things Microsoft Fabric!

March Fabric Community Update

Fabric Community Update - March 2024

Find out what's new and trending in the Fabric Community.

Top Solution Authors
Top Kudoed Authors