The rows parents have through the has-many relation relation (a @pg_has_many note of
T), in one query: items[i] belongs to parents[i]. Free it with free_loaded; the items
read from its result.
posts, error := Pg.load_many(db, users, "posts");
for users print("% wrote % posts\n", it.email, posts.items[it_index].count);Not run: the example is marked ignore.
Not run: it needs a PostgreSQL server.
Fields
- items: [][] Item
- rows: [] Item
- Every item once;
itemsare views into it. - result: Result