Hi there. All I read about composite keys is that they should be avoided. Here is my basic problem:
Very Basically the three tables would be Orders, Order_items, and products
Orders would have an autonumber PK (oID)
Products would have an autonumber PK (pID)
Order-items would need a composite PK to be unique. It would consist of the oID and the pID.
I understand that isn't the preferred method of doing things. This is just a small project and it won't be complicated but for the sake of experience I would like to follow best practices. How can I work around this?
Very Basically the three tables would be Orders, Order_items, and products
Orders would have an autonumber PK (oID)
Products would have an autonumber PK (pID)
Order-items would need a composite PK to be unique. It would consist of the oID and the pID.
I understand that isn't the preferred method of doing things. This is just a small project and it won't be complicated but for the sake of experience I would like to follow best practices. How can I work around this?
Comment