码迷,mamicode.com
首页 > 数据库 > 详细

VS2008 C++ ODBC mysql datasource

时间:2016-01-22 21:18:44      阅读:167      评论:0      收藏:0      [点我收藏+]

标签:

Linker: http://blog.csdn.net/ztz0223/article/details/7614091

Hyperlink before introduce the basical ODBC between VS2008 C++ project and Mysql datasource.

The issue I met is 

MySQL ODBC "architecture mismatch" Error

Sovle solution:

If you attempt to use ODBC to run a MySQL application and run into the following error:

[Microsoft][ODBC Driver Manager] The specified DSN contains an 
architecture mismatch between the Driver and Application

This means there is a 64-bit versus 32-bit mismatch.

Most likely, you‘re running 64-bit Windows, as well as 64-bit MySQL ODBC connector, but the application is 32-bit.

If this is the case, you will also need to install the 32-bit MySQL ODBC connector, and then create the connection from the 32-bit ODBC.

odbcad32.exe is the file to create the connections. Both 64-bit and 32-bit files have the same name, just differing locations.

This is the default location for the 64-bit ODBC:

C:\Windows\System32\odbcad32.exe

This is the default location for the 32-bit ODBC:

C:\Windows\SysWOW64\odbcad32.exe

And should you need to install MySQL ODBC, there are good instructions here (both for MSI and Manual installs).

Hope this helps.

Reason : Machine version 32 bit and 64 bit.

VS2008 C++ ODBC mysql datasource

标签:

原文地址:http://www.cnblogs.com/gycui/p/5151782.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!