It's much harder than I thought (I'm pretty much a noob at this)
At first I was thinking of storing the individual's id in one column and how the individual relates to other individuals in the other.
e.g.:
|| Tom || Gary:Brother; Joe: Father; Janet:Mother ||
--------------------------------------...
|| Gary || Tom:Brother; Joe:Father; Jane:Mother||
etc..
But this has so many problems i can't even list them all out.
The obvious problem is that this database would grow exponentially in size, and each time a new person is added, all the previous data would have to be changed (e.g. Tom adds a new boy, then all of Toms siblings would have to have a new nephew added).
So then I was thinking that each person only store the relational information of people directly related. That way Tom's brother would read Tom's data and find Tom's son's data and then in turn read that.
The problem with this is that the database would have to be read each time a person if found (If someone reads Gary's info, the database would have to be accessed 3 times to read Tom Joe and Janet's relational info, and if those turn up new 5 relations then the database would have to be accessed another 5 times) and family trees tend to be huge, so that's very inefficient..
So how are you supposed to make a family tree database..?
No links to Ancestry.com please:)
Tags: