Relationship Question

  • Thread starter Thread starter SuseMarc
  • Start date Start date
S

SuseMarc

Guest
Ok, ive done some reasearch on my previous problem now as well as buying 3 books, im not sure if ive done the relationships correctly, i need to have multiple "IProductID"s in one Order, however when i try to add more than one using the current relationship (as seen in the .jpg i attached) i get a duplication error. Should the relationship between the InputMedia and the IOrderDetail be many to one as opposed to one to many? If so how do i go about changing it? :( The IProductID in the InputMedia table is an autonumber and the one in the IOrderDetail is a longInteger.

Can anyone shed some light on my predicament? Would be much appreciated!

Cheers,

Marc.
 

Attachments

  • relationship.jpg
    relationship.jpg
    29.9 KB · Views: 309
The relationship looks OK
What data is in there initially, and what are you adding?
If there's another IOrderDetail record with the same OrderID and IProductID then you should get an error. If it's just one or the other then it should be fine.

Hang on, just had a thought... when you created the IOrderDetail table, did you set the OrderID and IProductID columns to "Indexed: Yes (No Duplicates)"?
 

Users who are viewing this thread

Back
Top Bottom