While migrating an application from MSSQL 2005 and Server 2003 to MSSQL 2008 x64 and Server 2008 x64, I ran into an problem with the ODBC connection. The application uses a System DSN to connect to my BlackBerry Enterprise Server, BESMgmt. Settings were identical on both boxes, and verification within the ODBC manager worked.
When I tried to verify the DSN from within the app, I received the following error:
Can't connect, error [Microsoft][ODBC Driver Manager] Data source name not found and no default driver specified
A variant of this error is:
Microsoft OLE DB Provider for Microsoft OLE DB Provider for ODBC Drivers (0×80004005)
[Microsoft][ODBC Driver Manager] Data source name not found and no default driver specified
Most of the search results for that error turned up permission problems, and recommended explicitly granting access to the Registry key at the HKLM\SOFTWARE\ODBC\ODBC.INI. This wasn't my problem, and is also the reason that User DSNs exist.
It turns out that if you launch the ODBC Manager from the Start menu, you're getting the 64-bit version. 32-bit applications don't see DSNs created in the 64-bit ODBC Manager, and will fail one of the errors above.
The 32-bit ODBC Manager is located at C:\Windows\SysWOW64\odbcad32.exe
Launch that to manage DSNs for 32-bit applications and resolve this error.
Tags: 32-bit, 64-bit, Microsoft, MSSQL, ODBC, Server 2003, Server 2008, SQL, Windows, x64, x86



August 13th, 2010 at 1:28 am
Thanks!
August 18th, 2010 at 2:52 pm
Thank you very much, your post just solve my problem.
September 22nd, 2010 at 8:38 am
I am still getting the same error from my Visual Basic 6.0 application: "ODBC Driver Manager – Data source name not found and no default driver specified".
I can see the DSN and it tests fine, using the 32-bit ODBC Driver Manager.
Thanks for the article. I did not know about the 32-bit Driver Manager before.
September 27th, 2010 at 11:11 am
Wow, this was the one thing I needed; I was banging my head over this for hours. Grr to MSFT for defaulting to 64 bit (or at least not warning you about it).
September 27th, 2010 at 11:14 am
I also needed to alter the registry to make my program work correctly. See this StackOverflow question for more details: http://stackoverflow.com/questions/1134827.
November 30th, 2010 at 1:36 am
Hi
Thanks a lot for this tip, you made same people very happy.
Thanks a lot.
December 15th, 2010 at 12:21 pm
Perfect! This helped me a lot.
December 20th, 2010 at 3:26 pm
This is exactly what I needed to know. Just couldn't figure out why this old code no longer worked. But in the year since I last worked on this code I got a 64-bit computer. D'oh!
January 26th, 2011 at 5:05 pm
Thanks!
All the best,
Wyniki Joker