From 18f723723ed93b78c52be3f1f9e4137006299812 Mon Sep 17 00:00:00 2001 From: Boris Kolpackov Date: Wed, 4 May 2016 20:59:54 +0200 Subject: Ignore section logic when dealing with container elements The container member itself can be in a section. --- odb/relational/pgsql/context.cxx | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'odb/relational/pgsql') diff --git a/odb/relational/pgsql/context.cxx b/odb/relational/pgsql/context.cxx index f8a9fe2..cd73cf9 100644 --- a/odb/relational/pgsql/context.cxx +++ b/odb/relational/pgsql/context.cxx @@ -170,7 +170,11 @@ namespace relational virtual bool pre (member_info& mi) { - return (section_ == 0 && !separate_load (mi.m)) || + // If we have a key prefix (container), then it can't be in a + // section (while mi.m can). + // + return !key_prefix_.empty () || + (section_ == 0 && !separate_load (mi.m)) || (section_ != 0 && *section_ == section (mi.m)); } -- cgit v1.1