Urgent Normalisation help!!!

  • lol i don't know i am learning normalisation.

    will i be able to relate the order table with the customer by customer ID

  • Lunch/work back for a bit.

    Okay.

    Let's think about the relationship between Customers and Orders. How many orders could a customer have?

  • One customer can have many orders

  • Okay, one customer, many orders; where do you want to store the customer information, in the customer table or the order table?

  • Customer information is in the customwe table

  • Can you explain why based on what you have learned so far about normalization?

    Also, how will you relate the two tables?

  • Each table has its own data.

    The customer details will be in the customer table.

    Order details in the order table etc...

    Each table has its own primary key.

    Tables are linked via a foreign key

  • Aty01 (3/28/2012)


    Each table has its own data.

    The customer details will be in the customer table.

    Order details in the order table etc...

    Each table has its own primary key.

    Tables are linked via a foreign key

    What I was looking for was more along this:

    Storing the customer information in the order results in repeating data. By moving this data to a separate table we create one copy of this data. In this case, we replace the customer information with a single item, such as customer numbner or customer id and use that to link the customer and order tables.

    Make sense?

  • I think so

  • Aty01 (3/28/2012)


    I think so

    So, show us what you have so far.

  • Lynn Pettis (3/28/2012)


    Aty01 (3/28/2012)


    I think so

    So, show us what you have so far.

    Praying hard poster does not says "I have a head ache" 😀

    _____________________________________
    Pablo (Paul) Berzukov

    Author of Understanding Database Administration available at Amazon and other bookstores.

    Disclaimer: Advice is provided to the best of my knowledge but no implicit or explicit warranties are provided. Since the advisor explicitly encourages testing any and all suggestions on a test non-production environment advisor should not held liable or responsible for any actions taken based on the given advice.
  • as your desire ,you can do is ,

    table address

    addressid

    address

    town

    postcode

    table customer

    customerid

    Customer Forename

    Customer Surname

    addressid

    Email

    table supplier

    Supplier ID

    Supplier Name

    addressid

    Supplier Tel No

    table product

    productid

    Category

    productname

    Price

    productstock

    Stock ID

    Stock Description

    productid

    Qty in Stock

    Table order

    oderid

    productid

    customerid

    orderdate

    table orderdetail

    orderdetailid

    orderid

    qty

    and the primary key is chosen by the 1st column of the table .

  • Friend: Check out the following link

    http://www.youtube.com/watch?v=c-Zfgg5Ayyc&feature=related

    ~ Lokesh Vij


    Guidelines for quicker answers on T-SQL question[/url]
    Guidelines for answers on Performance questions

    Link to my Blog Post --> www.SQLPathy.com[/url]

    Follow me @Twitter

  • Above link is totally in agreement with Gail Shaw's explanation

    ~ Lokesh Vij


    Guidelines for quicker answers on T-SQL question[/url]
    Guidelines for answers on Performance questions

    Link to my Blog Post --> www.SQLPathy.com[/url]

    Follow me @Twitter

  • One more link: http://www.youtube.com/watch?v=cbJ-xaBfWLM&NR=1&feature=endscreen

    ~ Lokesh Vij


    Guidelines for quicker answers on T-SQL question[/url]
    Guidelines for answers on Performance questions

    Link to my Blog Post --> www.SQLPathy.com[/url]

    Follow me @Twitter

Viewing 15 posts - 46 through 59 (of 59 total)

You must be logged in to reply to this topic. Login to reply