[odb-users] Circular relation problem with external file mapping

Boris Kolpackov boris at codesynthesis.com
Fri Jul 19 05:05:47 EDT 2013


Hi Romain,

Romain Gros <grosr.romain at gmail.com> writes:

> #pragma db object(QuestStep) definition
> #pragma db member(QuestStep::quest_) get(get_quest)
> set(set_allocated_quest) not_null column("idquest")
> 
> #pragma db object(Quest) definition
> #pragma db member(Quest::steps_) get(get_steps) set(set_steps)
> value_not_null inverse(quest_)
> 
> `get_steps` returns a `::google::protobuf::RepeatedPtrField< ::QuestStep >*`.

What are the types of the QuestStep::quest_ and Quest::steps_ data
members? Based on your mapping, they should be pointers to objects
of some sort.


> Now, when I try to compile, I got this error: `unable to map C++ type
> '::QuestStep'`.

That would normally mean that QuestStep is treated as a value rather
than an object. What does the line that this error points to contain?
And in the future always show what the error points too -- I have no
way of knowing what it is!

Boris



More information about the odb-users mailing list