Hi guys!
I have a question if I have two tables one with the information of every id and one that determines the deep hierarchy of each id, how can I join the two of them? For example,
Detail table:
ID | VALUE | ID_PARENT |
1 | 4 | 2 |
2 | 5 | 4 |
3 | 7 | 4 |
4 | 2 | NULL |
Hierarchy table:
ID_CHILD | ID_PARENT | LEVEL |
1 | 2 | 1 |
1 | 4 | 2 |
2 | 4 | 1 |
3 | 4 | 1 |
output in the explore:
FilterID: ‘4’ | |||
---|---|---|---|
ID | ID_CHILD | LEVEL | VALUE |
4 | 22 | ||
4 | 2 | 2 | 9 |
4 | 1 | 1 | 4 |
4 | 3 | 1 | 7 |
Thank you!! I haven’t found any information about this type of problem, so any help is welcome!