Home Forums Programming General Hierarchy without cursor/loop RE: Hierarchy without cursor/loop

  • Luis Cazares - Monday, March 20, 2017 12:17 PM

    ansaryarshad - Monday, March 20, 2017 12:01 PM

    Hi Thom,

    Thanks for the post . But the condtion

    E.MgrID = H.EmpID
     will not work for Node C as its Parent Node is B which is not in H table

    BR
    Arshad

    I don't understand what you're talking about. Thom's code works as expected and I'm sure that he tested it before posting.
    What do you mean when you state that the condition will not work?

    Luis is right,. I did test it. Did you, ansaryarshad? If so, what were the results you got and what was the SQL you ran? Wondering if you modified it incorrectly.

    On a different note, Luis, found your articule quite interesting. I avoid hierarchy data as much as I can, so I can't see any applications for myself, but if the OP does have as many users as you did, then would be worth while him making use of.

    Thom~

    Excuse my typos and sometimes awful grammar. My fingers work faster than my brain does.
    Larnu.uk