[odb-users] shared_ptr<vector<T>>

Boris Kolpackov boris at codesynthesis.com
Fri Jan 24 01:05:24 EST 2025


MM <finjulhich at gmail.com> writes:

> Is builtin support provided for this when it is a data member of a class or
> one needs to help ODB with custom code?

Why not give it a try (or if you tried, say what is not working for you)?

This compiles for me and produces the expected database schema, at least:

#pragma db object
struct person
{
  #pragma db id auto
  std::uint64_t id;

  std::shared_ptr<std::vector<std::string>> names;
};



More information about the odb-users mailing list