Okay. Now I understand more clearly the problem.
So definitely add productId to the jobOrder, and remove it from the part table.
Now, the real question is do you use the same parts for the product every time, if you do, you could link them to the product instead, like a list of ingredients that are used to make a product. Now if parts can be used to make multiple products, you will need a glue table.
So basically it boils down to this now:
Product <--- JobOrder (forgive my messy semantics, it means that joborder has a fk to Product)
Product <--- Glue? <--- Part
-- or --
Product <--- JobOrder
JobOrder <--- Glue <--- Part
Again, I'm probably misunderstanding the project, but that's my solution from how I see it.
|