If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > General > Database Concepts & Design > Normalization

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 04-04-07, 14:49
philmetz philmetz is offline
Registered User
 
Join Date: Apr 2007
Posts: 15
Question Normalization

I gathered an unnormalized list as follows:
0NF
R1 = (ABN, Garage_Address, Garage_Tel, Garage_Fax, Tax_Invoice_No (Customer_No, Customer_Name, Customer_Address, Contact_Phone, Mobile, Vehicle_Info (Staff_No, Staff_Name, Advisor (Part_ID, Description, QTY, Unit_Price, Amount, Part_Total (Labour_ID, Description, Amount, Labour_Total)))))


Not i was wondering how the 1NF, 2NF and 3NF would look like if someone can help?

thx
Reply With Quote
  #2 (permalink)  
Old 04-04-07, 15:09
tomh53 tomh53 is offline
9th inning DBA
 
Join Date: Jan 2004
Location: In a large office with bad lighting
Posts: 1,036
1. Read this: http://www.phlonx.com/resources/nf3/

2. Try it yourself

3. Come back with a plan and we can help.
__________________

-- This is all just a Figment of my Imagination --
Reply With Quote
  #3 (permalink)  
Old 04-04-07, 15:36
philmetz philmetz is offline
Registered User
 
Join Date: Apr 2007
Posts: 15
here is wat iv done

PHP Code:
0NF
R1 
= (ABNGarage_AddressGarage_TelGarage_FaxTax_Invoice_No (Customer_NoCustomer_NameCustomer_AddressContact_PhoneMobileVehicle_Info (Staff_NoStaff_NameAdvisor (Part_IDDescriptionQTYUnit_PriceAmountPart_Total (Labour_IDDescriptionAmountLabour_Total)))))

1NF
R11 
= (ABNGarage_AddressGarage_TelGarage_FaxTax_Invoice_No)
R12 = (Customer_NoCustomer_NameCustomer_AddressContact_PhoneMobileVehicle_InfoStaff_NoStaff_NameAdvisorPart_IDDescriptionQTYUnit_PriceAmountPart_TotalLabour_IDDescriptionAmountLabour_Total)

2NF
R11 
= (ABNGarage_AddressGarage_TelGarage_FaxTax_Invoice_No)
R121 = (Customer_NoCustomer_NameCustomer_AddressContact_PhoneMobileVehicle_Info)
R122 = (Customer_NoStaff_NoStaff_NameAdvisor)
R123 = (Customer_NoStaff_NoPart_IDDescriptionQTYUnit_PriceAmountPart_TotalLabour_IDDescriptionAmountLabour_Total)

3NF
R11 
= (ABNGarage_AddressGarage_TelGarage_FaxTax_Invoice_No)
R121 = (Customer_NoCustomer_NameCustomer_AddressContact_PhoneMobileVehicle_Info)
R122 = (Customer_NoStaff_NoStaff_NameAdvisor)
R1231 = (Customer_NoPart_IDDescriptionQTYUnit_PriceAmountPart_Total)
R1232 = (Labour_IDDescriptionAmountLabour_Total
Anything i need to do?
Reply With Quote
  #4 (permalink)  
Old 04-04-07, 16:15
philmetz philmetz is offline
Registered User
 
Join Date: Apr 2007
Posts: 15
Post ok ignore the first one

OK iv changed the first one, heres the new thing:

0NF
R1 = (ABN, Garage_Address, Garage_Tel, Garage_Fax, Tax_Invoice_No (Customer_No, Customer_Name, Customer_Address, Contact_Phone, Mobile, Vehicle_Info (Staff_No, Staff_Name, Advisor (Part_ID, Description, QTY, Unit_Price, Amount, Part_Total (Labour_ID, Description, Amount, Labour_Total)))))

1NF
R11 = (Tax_Invoice_No, ABN, Garage_Address, Garage_Tel, Garage_Fax)
R12 = (Customer_No, Customer_Name, Customer_Address, Contact_Phone, Mobile, Vehicle_Info (Staff_No, Staff_Name, Advisor (Part_ID, Description, QTY, Unit_Price, Amount, Part_Total (Labour_ID, Description, Amount, Labour_Total))))

2NF
R11 = (Tax_Invoice_No, ABN, Garage_Address, Garage_Tel, Garage_Fax)
R121 = (Tax_Invoice_No, Customer_No, Customer_Name, Customer_Address, Contact_Phone, Mobile, Vehicle_Info)
R122 = (Tax_Invoice_No, Staff_No, Staff_Name, Advisor)
R123 = (Tax_Invoice_No, Customer_No, Part_ID, Description, QTY, Unit_Price, Amount, Part_Total, Labour_ID, Description, Amount, Labour_Total)

3NF
R11 = (ABN, Garage_Address, Garage_Tel, Garage_Fax, Tax_Invoice_No)
R1211 = (Tax_Invoice_No, Customer_No)
R1212 = (Customer_No, Customer_Name, Customer_Address, Contact_Phone, Mobile, Vehicle_Info)
R1221 = (Tax_Invoice_No, Staff_No)
R1222 = (Staff_No, Staff_Name, Advisor)
R1231 = (Tax_Invoice_No, Customer_No, Part_ID, Labour_ID)
R1232 = (Part_ID, Description, QTY, Unit_Price, Amount, Part_Total)
R1233 = (Labour_ID, Description, Amount, Labour_Total)




How is it?
Reply With Quote
  #5 (permalink)  
Old 04-05-07, 05:12
pootle flump pootle flump is offline
King of Understatement
 
Join Date: Feb 2004
Location: One Flump in One Place
Posts: 14,905
I'm moving this to db concepts & design - it is better suited to that forum.
__________________
Testimonial:
Quote:
pootle flump
ur codings are working excelent.
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On