Forum Discussion
Anonymous
2 years agoNot applicable
Tree Calculation/Aggregated Values Matrix
im struggling to create a table parent and child tree relationship, i have a parent and child table, i wanted to calculate the values with respect to their root parents like a family tree Chil...
- 2 years ago
Tree Relation=CONCATENATEX(FILTER(Data,PATHCONTAINS(PATH(Data[Child],Data[Parent]),EARLIER(Data[Child]))),Data[Child],"|")
Calculated Values formula keeps no change.
Anonymous
2 years agoNot applicable
wdx223_Daniel , Great, this works fine. May i know if its possible as well to get all the total for all grand child/children
| Child | Parent | Value | Tree Relation | Calculate Grand Child |
| Site1 | Site2 | 10 | Site1 | 10 |
| Site2 | Site3 | 20 | Site2,Site1 | 20+10=30 |
| Site3 | Site4 | 15 | Site3,Site2,Site1 | 15+20+10=45 |
| Site5 | Site4 | 5 | Site5 | 5 |
| Site4 | Site6 | 20 | Site4,Site5,Site3,Site2,Site1 | 20+5+15+20+10=70 |
| Site6 | 100 | Site6,Site5,Site4,Site4,Site2,Site1 | 100+20+5+15+20+10=170 |
Thanks again.
wdx223_Daniel
Community Champion
2 years agoTree Relation=CONCATENATEX(FILTER(Data,PATHCONTAINS(PATH(Data[Child],Data[Parent]),EARLIER(Data[Child]))),Data[Child],"|")
Calculated Values formula keeps no change.
- Anonymous2 years agoNot applicable
Thanks . but i got a wrong computation on the calculated values..
- Anonymous2 years agoNot applicable
the relation is right, but the calculated value is wrong.
the formula i have is below but shows wrong ouptut.
CalValue = SUMX(FILTER('ParentChild',PATHCONTAINS(EARLIER('ParentChild'[Tree]),'ParentChild'[Child])),'ParentChild'[Value])