[odb-users] Question about complex query implementing
Music samal
zxbzswxr at gmail.com
Thu Nov 29 20:50:24 EST 2018
If I have a class which has a std::string menber
and It is stored in database as Name + index form
#pragma db object
class A{
public:
A(){}
friend class odb::access;
#pragma db id
uuid m_id;
#pragma db column("name")
std::string m_strName;
};
If I want to store A object in the database, and make them show like that
A1 has name AName_001;
A2 has name AName_002;
.....
AXX has name AName_0XX;
.....
AZZZ has name AName_ZZZ;
A1,A2.... AXX ....AZZZ are all A objects.
If I want to query the an A object with this name form AName_XXX which has
the biggist index, maybe it's AName_657 or other number and I want to
return this number.
what should I do to implement this query
More information about the odb-users
mailing list