When the VS project loads the Libmysql.lib
That is, additional include directories, additional library directories, and additional dependencies are set up, as if the compilation appears as follows:
Error LNK2019: unresolved external symbol [email protected], the symbol is referenced in function _main
Error LNK2019: unresolved external symbol [email protected], the symbol is referenced in function _main
Error LNK2019: unresolved external symbol [email protected], the symbol is referenced in function _main
Error LNK2019: unresolved external symbol [email protected], the symbol is referenced in function _main and other errors, because the VS project default is 32 bit, and MySQL is 64 bit
In addition to reloading MySQL, you can change the project properties, and the project properties are changed in two places:
If you change only one place, you will see an error similar to the following: the target computer and the analog computer are incompatible
However, there is no merit victory at this time, the cheap will also report the lack of Libmysql.dll dynamic library
The path to the dynamic library is:
C:\Users\ASUS\Documents\Visual Studio 2012\projects\connectmysql2\x64\debug (This is my local project), because after changing the above configuration, there are many such directories, Remember that there is exe executable file in the same directory, and then solved (in fact, the compilation phase through--generation EXE, but the link stage less dynamic library, so put in the EXE in the same level directory)
VS Project and mSQL incompatible solutions