racing_couple ID (PRIMARY) breeding_couple ID (PRIMARY) egg IDpar(FOREIGN KEY)
I have 2 IDs from 2 different tables (racing_couple and breeding_couple) and they are primary keys. In 3. table (egg) I have IDpar which is foreign key and references ID in racing_couple and breeding_couple. Tables represents racing and breeding couple of pigeons, table "egg" represents egg of racing or breeding couple. And I'm using IDpar to identify which egg belongs to which couple.
Note There are other fields in both database but they are mostly varchar and not so relevant to this problem.
If I have something like this in both databases. How to know which IDpar has value from racing_couple and which IDpar has value from breeding_couple. I think I made mistake by making my database like this, but is there any way to make that work?
ID(racing_couple) 1 2 ID(breeding_couple) 1 2 IDpar(egg) 1 (ID racing_couple) 1 (ID breeding_couple) 2 (ID racing_couple) 2 (ID breeding_couple)