Condition on basic model to determine if Id of row is in grouping of aggregate model?

I have two aggregate models and I want to use a condition that limits one aggregate model to only those record IDs that are in the other, is this possible?

I tried a condition of Record Id is IN the Id Field from my parent model, but I get an error that the Id field is not coming in on my parent Aggregate model. 

Next I tried hacking the XML so the condition is Record Id IN the 'countdistinctId field from my parent model, but I get an error that there is not record a Id that = 12 (12 is the number of rows in my parent aggregate model).

My use case is I have an aggregate model that pulls in fields from several other aggregate models in a single table, because I need basically a matrix table that shows columns of an aggregate value for each calendar month. That’s working, using UI-Only fields with Model_Lookup formulas.

The tricky part is that I also want to use table filters on this table. Right now, filters only act on the values from my main model, and not the other models.

I was thinking I could use a model action that triggers when my parent model is requeried, and the actions are set a condition on each of the other models and requery them. 

Open to other ways of achieving this, like if there’s some way to say, “if this filter is activated on my parent model, then set the same filter on my child models and give them the same value.” Maybe a snippet could do something like that?

Thanks for any advice! Let me know if posting code would help.

Neat project. My only thought is instead of using actual table filters, locate a navigation component above the table. Nav components are buttons that do whatever you want so you could set one of the navigation items to activate a condition and requery 5 models at the same time. If you need the ability to get filter suggestions like a table filter set to automatic would provide, you may be able to accomplish this with the search component. The search component could be set to search the model fields that you want to filter on, then activate conditions on models when the selection is made (I believe). This two wound have to be inserted above the table instead of in its header like an actual table filter, but with some wrappers and formatting, you could probably make it look pretty nice.

Bill points out using two separate models to return the records you want. Have you looked at “Adopt Rows” action. This allows you to adopt the rows of one model on ObjectA into another model on ObjectA. It may work in this case. You could set up two models on the Task Object, then adopt the rows of one into the other or adopt the rows of both into a third model. Once all the rows have been adopted into a single model, you can display them all in a single table. I have never done this, but it is worth a look.

Great ideas!!! Will post if I get something working. 

Have you seen Pat’s genius idea here:   It might be what you are looking for

Yes! I think that will do it. Should work the same for Ag to Ag cross models. 

Yes, I regularly use pat’s cross model linked conditions with AG models. Works like a charm. :slight_smile: