Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.misc -> Re: multilevel hierarchy query
David,
Thanks. That was an interesting read.
Unfortunately, I've inherited the tables and can't change them, just read them.
However, I can estimate the maximum number of levels in the tree. With this in mind, I tried a brute force approach. This seems to get all the staff below a manager (as long as they're no more than 6 levels deep). Not elegant, but it seems to be effective.
SELECT tblStaff.StaffID, [tblStaff]![StaffID] & " " &
Thanks,
Bruce
Received on Wed Feb 16 2005 - 12:17:22 CST