How do I setup relationship for these 2 tables?
Posted on 2014-11-09
I'm using sql express 2012 for an exercise.
If I have a Auction table(PD AuctionID) and a Person table(PD PersonID) with the following condition.
The auction table would have many auctions. A person can register to attend only one auction.
1. I think I would add a PersonId(FK) column in Auction Table and then add a AuctionID in Person table(FK).
2. In Design diagram, I dragged the AuctionID (PD) to the Person table's FK of AuctionId, that creates a Key and a infinite sign (On Person table side), which means one-to-many from Auction to Person. So a Auction will have many person in it.
3. How do I create a one-to-one relationship from person to Auction? this is so that a person can only attend one Auction?