• Status: Solved
• Priority: Medium
• Security: Public
• Views: 273

# Multi layer structure in Powerbuilder

I have a problem with traversing thru tree structure. I'm not able to calculate values at all levels.

PartnerA--->owenedby-->PartnerB--->owenedby-->PartnerC--->owenedby-->PartnerD--->owenedby-->PartnerH->owenedby-->PartnerI  AND  PartnerJ
|--->owenedby-->PartnerE--->owenedby-->PartnerG                  |--->PartnerZ AND PartnerK
|--->owenedby-->PartnerF
A is owned by B of 40%
B is owned by C of 100%
C is owned by D of 98% and E of 1% and F of 1%
D is owned by H of 100%
H is owned by I of 80% and J of 20%
E is owned by G of 100%
I is owned by Z of 80% and K of 20%
Can you please suggest me how to calculate the percentage value at each level.

0
venkat4sv
1 Solution

Commented:
lets say if you have a value in A then

b=a*.40
c=b
d=c*.98
e=c*.01
f=c*.01
h=d
i=h*.80
j=h*.20
z=i*.80
k=i*.20

try them
Gajender
0

## Featured Post

Tackle projects and never again get stuck behind a technical roadblock.