two method.
1.use two fields that are parent id and child id to store the parent-child relation.
eg parent id , child id
-1 1
1 2
1 3
2 4
2.use two fields that are level and order
eg. level order
1 1
2 2
3 3
1` 4
2 5
the first method is good for manipulate the data, if you create a foreign key
for these two fields, remember add on delete cascade.then deleting the node of the tree
is quite easy.
but you have to use recursion to build the tree, it is slow.
the second method is good for build the tree, but the performance of manipulation is low.
so base on your system requirement to choice the suitable method