Can't seem to find this on the community board, but if it has already been answered - I'd appreciate a link.
I have Projects and Subprojects. The latter being the child. So there are a few Subprojects for every Project. On the other hand, I have Project managers. 
I want to have a "Tasks" table with all the tasks assigned to Project managers. 
My issue is that I want tasks to be EITHER created related to the Subproject, OR related to the main Project. 
The same exact relationship issue I encounter is when I have "Payments". 
A payment can be to a subcontractor - and therefor related to a Subproject. 
OR a payment can be to a Sales agent who brought the Project - and then it would be to the project. 
If I create two tables for these (i.e. "Project Tasks" and "Subproject Tasks" or "Project Payments" and "Subproject Payments") then it really just duplicates a lot and it also makes it impossible to create a normal interface to see all tasks assigned to me for example. 
Would appreciate any pointers on how to structure this correctly. 
Thank you!



