VS2017 C + + operation MySQL Database

Source: Internet
Author: User

1. install mysql first

Specific tutorials can refer to 52446608

Note When installing the product, remember to choose MySQL Connector C,

2. After installing mysql , start the configuration, click Project , Click Project Properties,

3. Select the address of the include file in the add-in directory of the MySQL installation address in thegeneral in the additional include Directories . C:\Program files\mysql\mysql Connector C 6.1\include,

4. Select the linker to add the address of the Lib file in your MySQL installation address in the additional library directory in the general, as I am C:\Program files\ Mysql\mysql Connector C 6.1\lib,

5. Click Input in the linker to add libmysql.libto the additional dependencies, note that libmysql.lib is not Libmysql.dll ,

6. then copy the libmysql.dll from the C:\Program files\mysql\mysql Connector C 6.1\lib to the project's in x64 ,

Note the path

7. change the operating platform to x64,

Problems that arise

If you just downloaded mysql sever, you will see an issue like the one that cannot locate the ordinal 3283 , the workaround is to install MySQL Connector C.

Run MySQL Install the product there and put the MySQL Connector C Hook it up, then follow the above process to get it over again.

VS2017 C + + operation MySQL Database

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.