[QODBC-ALL] Troubleshooting - Data source name not found and no default driver specified
Posted by Jack - QODBC Support on 17 January 2018 02:27 PM
Troubleshooting - Data source name not found, and no default driver specified
I have QODBC running on a terminal server.o
I can use 64-bit Excel to query QODBC via the "from other sources." I have set up a 64-bit remote DSN that talks to the user DSN.
I have written a test program in .net that connects to QODBC and successfully returns data.
When I run the same code within an Excel Add-in. I get the error that it cannot find the data source name:
ERROR [IM002] [Microsoft][ODBC Driver Manager] Data source name not found and no default driver specified
This occurs on my test application when I put in the wrong DSN. That is, it's not a 32/64-bit compatibility error, as you get a different message.
I can use QODBC in every way other than running as an Excel Add-in. Can you please advise where I have gone wrong?
The data source you are attempting to connect to does not exist on your machine.
On Windows, data sources are created by the Microsoft ODBC Administrator. The available System data sources are listed in the System DSN tab. The User data sources available for the currently logged-on user are listed in the User DSN tab.
You do not have permission to access the location where the data source is stored.
On Windows, the user account attempting to access the data source needs sufficient permissions to read the registry key where the data source is stored. System data sources are stored under HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBC.INI. User data sources are stored under HKEY_CURRENT_USER\Software\ODBC\ODBC.INI.
You are using a DSN-less connection on Windows that specifies a driver whose architecture differs from the applications. For example, you are using a 64-bit application, but the driver you specify in the connection string is only available as a 32-bit library. The application and ODBC driver architecture must be the same.
Please refer below-mentioned link for more details: