[odb-users] indirect relatioship between objects with std::vector<boost::variant<...>>

Boris Kolpackov boris at codesynthesis.com
Thu May 17 11:43:40 EDT 2018


MM <finjulhich at gmail.com> writes:

> The behavior that I'm looking for is that if I persist A, then, I
> would want my odb pragmas to persist the Xs and the Ys, but only if
> they are not persisted already.
>
> Similarly,  if I load A, and the Xs and Ys instances are not loaded
> already, I'd want to load them as well.

Normally this kind of application-specific logic is best implemented
using database operation callbacks and/or custom sessions.

Boris



More information about the odb-users mailing list