VS2008 C + + ODBC MySQL DataSource

Source: Internet
Author: User
Tags driver manager odbc

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'll also need to install the 32-bit MySQL ODBC Connector, and then create the connection from th E 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.

The default location for the 64-bit ODBC:

C:\Windows\System32\odbcad32.exe

The default location for the 32-bit ODBC:

C:\Windows\SysWOW64\odbcad32.exe

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

Hope this helps.

Reason:machine version, and the bit.

VS2008 C + + ODBC MySQL DataSource

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.