mysql-modern-cpp
mysql-modern-cpp copied to clipboard
Lightweight header-only wrapper for MySQL with simple and convenient usage in modern C++ (C++11 or later)
introduce two new connection options _ssl_enforce / _ssl_verify_server_cert and pass them through to MYSQL_OPT_SSL_ENFORCE / MYSQL_OPT_SSL_VERIFY_SERVER_CERT
1>D:\project-vs\vs\mysqlTest\mysql+++\mysql+++.h(157,38): error C4996: 'std::iterator': warning STL4015: The std::iterator class template (used as a base class to provide typedefs) is deprecated in C++17. (The header is NOT deprecated.) The C++ Standard...
To write a `daotk::mysql::connection::query` wrapper like this: ```cpp daotk::mysql::result DbClient::exec(const std::string& sql) { if (!m_connection.is_open()) { return daotk::mysql::result(); } try { return m_connection.query(sql); } catch (const daotk::mysql::mysql_exception& exc) { //...
Please change the include path of `mysql.h` and `errmsg.h` from ```cpp #include #include ``` to ```cpp #include #include ``` since the default path for these files does not contain `mysql`....
Build with `g++ -Wall -Wextra -O2 -std=c++11 -I. -o test test.cpp -lmysqlclient -lz -lzstd -lssl -lcrypto -lresolv -lm`