I've been struggling with some logic that will return department number roll-ups to the highest level, in this case the queen bees.
My data is like this...
|Joe||Worker Bee||200||King Bee 1|
|Mary||Worker Bee||300||King Bee 2|
|Larry||King Bee 1||450||Queen Bee 1|
|Mo||King Bee 2||475||Queen Bee 2|
|Anita||Queen Bee 1||100|
|Toni||Queen Bee 2||105|
|El Jeffe||Worker Bee||335||King Bee 2|
|Shemp||Worker Bee||250||King Bee 1|
I need to return data rolled up by Queen like this...
Hi Nitin, my pseudo dataset may be wrong. I like being told the answer, but to understand the hierarchy function I really need to dig into the documents Gysbert pointed me towards.