1. I use winddow 10 , vs2002 C++ ,MySQL community 8.0.32, Connector C++8.0.32
2. the vsc++ and mySQL seemed already linked successful, because I can query or insert record with vsc++ in mySQL with SQL session.
3.When I test the sample code in page 6 ,in "X DevAPI User Guide" , there is alway build problem happened :
#include <iostream>
#include <string>
#include <mysqlx/xdevapi.h>
using namespace std;
using namespace mysqlx;
int main()
{
Session mySession("localhost", 33060, "root", "passwd");
Schema db = mySession.getSchema("sakila");
Collection act = db.getCollection("actor"); // get table info
DocResult res = act.find("first_name like :param")//RowResult
.limit(1)
.bind("param", "L%").execute();
cout << res.fetchOne();
mySession.close();
}
above is my code try to select data from sample database "sakil",tabel "actor".
build stop in header file "xdevapi.h" ,said "abnormal unhandled" in
template<typename...T>
Session(T...options)
try
: Session(SessionSettings(options...))
{}CATCH_AND_WRAP
i don't know how to do , very appreciate for your help
2. the vsc++ and mySQL seemed already linked successful, because I can query or insert record with vsc++ in mySQL with SQL session.
3.When I test the sample code in page 6 ,in "X DevAPI User Guide" , there is alway build problem happened :
#include <iostream>
#include <string>
#include <mysqlx/xdevapi.h>
using namespace std;
using namespace mysqlx;
int main()
{
Session mySession("localhost", 33060, "root", "passwd");
Schema db = mySession.getSchema("sakila");
Collection act = db.getCollection("actor"); // get table info
DocResult res = act.find("first_name like :param")//RowResult
.limit(1)
.bind("param", "L%").execute();
cout << res.fetchOne();
mySession.close();
}
above is my code try to select data from sample database "sakil",tabel "actor".
build stop in header file "xdevapi.h" ,said "abnormal unhandled" in
template<typename...T>
Session(T...options)
try
: Session(SessionSettings(options...))
{}CATCH_AND_WRAP
i don't know how to do , very appreciate for your help