I have a table that holds all my organisation hierarchy and I want to split the table in to classes
Example of table
OrgID ParentID Level Name
1 1 0 Unit1
2 1 1 Unit2
3 1 1 Unit3
4 2 2 Unit4
5 2 2 Unit5
6 4 3 Unit6
I would like to create classes for each of the level that will hold the OrgID and the Name as objects so that if I create a hierarchy using the classes I would be able to drill from level0 all the way to level3
I would expect Level0 class to have Unit1, Level1 to have Unit2 and Unit3 etc.
Any help would be gratefully received.
Suz
Example of table
OrgID ParentID Level Name
1 1 0 Unit1
2 1 1 Unit2
3 1 1 Unit3
4 2 2 Unit4
5 2 2 Unit5
6 4 3 Unit6
I would like to create classes for each of the level that will hold the OrgID and the Name as objects so that if I create a hierarchy using the classes I would be able to drill from level0 all the way to level3
I would expect Level0 class to have Unit1, Level1 to have Unit2 and Unit3 etc.
Any help would be gratefully received.
Suz