AnsweredAssumed Answered

Relationship Filtering working (and not working)

Question asked by user375 on Oct 25, 2016
Latest reply on Oct 26, 2016 by user375

I have 2 sets of similar relationships, one is working successfully while the other one isnt and I cant see why. What I am trying to do is "filter" a set of related records by an unrelated "global" table. This is for CWP so I cant use filtered portals or scripts to set a global field, etc. I would rather not setup static fields for every filter I might need.


Example: parent record with 3 child records. In the relationship that works, I inserted my global table (only 1 record with 2 filter fields defined and populated with values to match on), between my 1st child occurrence and another table occurrence of the same table, child2. The global table is matching on all child records globally (child::id [X] global::filter1) on the left and matching ( global::filter1 [=] child::gender) on the right. Works like a charm. From the parent record, I get the 1 child record matching the value of my global filter AND my parent ID.


I have a 2nd set of relationships with the same scenario except using a different filter field,so its (child::id [X] global::filter2) on the left and ( global::filter2 [=] child::age) on the right. But it does NOT apply the "filter". From the parent, what I get are all child table records where child::age = 16, but not restricted to my parent.


Global IDfilter1 filter2


Child IDGenderAgeParent


Parent ID1 has 3 related children:

relationship 1 returns single record (ID11) matching "Boy" although there are numerous boys in the table to all parents.

relationship 2 returns multiple records of all children 16 years old regardless of parent - where I would expect ID10 returned.


Any ideas?