Results 1 to 3 of 3
  1. #1
    Join Date
    Apr 2010

    Lightbulb I need some basic explanation about constraints, ONE-TO-ONE, ONE-TO-MANY etc

    I am having difficulties in understanding this constraints between entity sets (tables)


    if someone could explain me the logic behind this concepts I would be grateful.


  2. #2
    Join Date
    Jun 2004
    Arizona, USA
    Here's a useful tutorial pertaining to referential integrity.
    "Lisa, in this house, we obey the laws of thermodynamics!" - Homer Simpson
    "I have my standards. They may be low, but I have them!" - Bette Middler
    "It's a book about a Spanish guy named Manual. You should read it." - Dilbert

  3. #3
    Join Date
    Dec 2007
    Richmond, VA
    I don't think that link quite answers your questions.

    ONE-TO-MANY Typical relationship between a parent and child table. For instance,
    you will have an order table, which contains your customer, date the order was placed and some other items. Then you would have an order_detail table, which would contain an entry for each item that is on the order, like item being purchased, how many units, etc...
    ONE-TO-ONE I kinda do not like these and would prefer that they just be folded into a single table. Say something like you have an order table and an order date table. The reason I do not like them is due to the redundancy of the primary key and the index, plus the additional complexity of maintaining the table. I have yet to see a good reason given to me to have a ONE to ONE relationship.
    MANY-TO-MANY Most times, something is wrong with your model and you have left something out in the middle of two tables that would properly join them together with a ONE to MANY relationship on both sides. See

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts