i m doing 1 website for multilevel marketing
there concept is if A add two person B on left and c on right then A will get commission. only if both his side that is left and right member are added else on commission.
And if B have added 2 person on his left and right B will get commission but A will get commission until C's Left and Right members are added.
this process goes on.. so i want to write store procedure for it so that A will get commission when B and C childs are added. Please Help