on 2016 Apr 01 8:16 PM
I'm trying to use a Rule to come up with the COUNT of all instances of an object that is stored in a nested collection three levels deep. My data structure looks like:
MainObject
StationsCollection
Stations
UnitsCollection
Units
TagTemplatesCollection
TagTemplates
Order
I want to be able to count all instances of the TagTemplates object that have a zero stored in its Order Property. My thought was that I would simply be able to use a Rule that would reference all instances of Stations object, Units object, and TagTemplates object (within their respective collections) and return the count of all TagTemplates that have an Order value of zero. A rule something like:
COUNT
StationsCollection Property 😆 All UnitsCollection Property 😆 All TagTemplatesCollection Property
EQSTR
Order Property
0
However, when I go to the property browser to specify the collection to pass to the COUNT function, it only lets me go two levels deep. As you can see below, when I select "All UnitsCollection", there is no way to expand to the next level down.
Am I doing something wrong, or is there a better way to do this?
Thanks
Tim
I think you are going to have to do nested for loops for each collection, and sum the count in a property on the Main object.
Are you familiar with how to loop over collections in agentry?
Michael
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
69 | |
13 | |
11 | |
10 | |
9 | |
9 | |
6 | |
6 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.