0

I have the following two tables

company_relationships

|ID|Company_ID|Affiliate_ID|<Relationship Info>|
+--+----------+------------+-------------------+

jobs

|ID|Company_ID|<Job Info>|
+--+----------+----------+

and I need to keep a record of job offers (i.e. a company offers a job to its affiliate). Do I use: job_offers

|ID|Job_ID|CompanyRelationship_ID|<Offer Info>|
+--+------+----------------------+------------+

or

|ID|Job_ID|Affiliate_ID|<Offer Info>|
+--+------+------------+------------+

or something else?

I want to use the first one, because relationship info applies to the job offer, but then Company_ID is specified by both Job_ID and CompanyRelationship_ID. Is there an issue with this / better schema to use?

1 Answer 1

0

If you go for the Option 1, how do you Identify the Affiliate? and that's why I think Option 2 is better, unless I am missing something

1
  • The affiliate is specified by the CompanyRelationship, as well as whatever configurations are specified for that relationship
    – Rob
    Commented Oct 28, 2014 at 18:36

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.