Lets say I have an Areas Table ( id, parentId, name, path ).
Given an Id, I'd like to get all childrens (children of children included, recursively) of the given area.
I do store in the path the path from the parents to the child.
Example:
1 NULL New York /1/
2 1 BRONX /1/2/
3 1 MANH /1/3/
4 3 UpWest /1/3/4/
5 3 MidEast /1/3/5/
So when asking for what are the children of New York, the query should return bronx, manh, upwest and mideast. and not only bronx and manh.