I am trying execute a recursive function.
Suppose I have a table
1 | 2
2 | 3
3 | 4
2 | 7
I want to know all the children and grandchildren of 1.
So I want my table to look like:
1 | 2
1 | 3
1 | 7
1 | 4
2 | 3
2 | 4
2 | 7
3 | 4
Is there some magic I can pull off?