I am building a TODO manager, and I am having trouble grasping how i should handle dependency relations within todo objects. here's a simplified layout

To_Dos
Fields: id (PK), title, due_date
PK: id

To_Do_Dependencies
Fields: dependent_id (FK To_Dos.id), dependee_id (FK To_Dos.id)
PK: dependent_id, dependee_id


So the deps table is basically a maping table maping a to do item to other to do items
one to do may have many dependencies and may be depended on by many to dos


So this is a many to many, but i can't wrap my head around how to specify this in RDBO

should I use a many to many? or a one to many and a many to one?  if i do that can i automagically get them from the mapping table?

Reply via email to