Account Hierarchy View

Client would like to be able to launch a skuid view off of any Account record that will then display all the related records for ANY account in the hierarchy. So for example, say we have a hierarchy that looks like this:

Parent Account

Child Account

Grandchild Account
Grandchild Account

Child Account
Child Account

The want to be able to launch a skuid page that will allow them to see all the contacts related to any of these accounts (And cases, opportunities, etc) from any account within the hierarchy. Is this possible or will they always need to start from the Parent account for the correct context?

The other piece is - how can we be sure we are capturing the entire hierarchy? Meaning how can I be sure that I am accounting for all related accounts? The hierarchy could have many levels. How to I make sure that the user can see all records related to all accounts if i don’t know how many levels deep the hierarchy could be?

Yes! Show me all the data!!!

This is possible, but only within limits. Within a new skuid page, create a model on Contacts that has a separate condition for every level of hierarchy you allow. Because you can traverse up the levels of the data model when picking the fields you want to use in your condition you can get to Account.Parent.ParentId which is the grandparent.

The important detail is to use the “Grouping logic” property of conditions to connect these conditions with OR operators. This will return data if ANY of these conditions are true.

Add that model to a table and you are in business. Rinse and repeat for all the other related objects…

So, add a condition for every level of the hierarchy you expect. If your hierarchy is truly limitless - we can’t help you. But we can get you close…

Thanks Rob. They say its limitless but I will push them on that and see what shakes out. The rest makes sense. Thanks for the reply.