Jump to content

the database normalization


runeveryday

Recommended Posts

StudyNo | Name  |  Sex   |   Email      |  ClassNo  | ClassAddress
01           john       Male      kkkk@ee.net  200401     A building 1
02           mary      famale   kkk@fff.net    200402     A building 2 

the above is a table.

StudyNo is the primary key,a friend of mine said the above is fit for the first normal form,but doesn't fit for the second.the reason is  "ClassAddress" partial dependencies on the key  ClassAddress,

why?who can explain it to me!

thanks very much.

 

Link to comment
Share on other sites

i can't understand.

table1:

StudyNo  |  Name  |  Sex  |      Email        |  ClassNo

      01            john        Male      kkkk@ee.net    200401     

      02          mary        famale    kkk@fff.net      200402 

table2:

ClassNo  | ClassAddress

200401      Abuilding1

200402      Abuilding2

 

 

are fit for the second NF,the primary key is StudyNo ,ClassNo

why the first doesn't  fit for the second NF

 

Link to comment
Share on other sites

Hi

 

Can each person only be in a single ClassNo, and does a person on have a single StudyNo? If so then it would appear splitting it into 2 tables has resulted in it being normalised. Duplicates have been removed (first normal form), all fields are dependent on the primary key (2nd normal form) and nothing is dependent on anything other than the primary key (3rd normal form)

 

Check the link on the thread on normalisation to the MySQL site:-

 

http://dev.mysql.com/tech-resources/articles/intro-to-normalization.html

 

All the best

 

Keith

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.