a - Normalizing a Data Model

1,017 views
967 views

Published on

Published in: Technology
0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total views
1,017
On SlideShare
0
From Embeds
0
Number of Embeds
19
Actions
Shares
0
Downloads
65
Comments
0
Likes
0
Embeds 0
No embeds

No notes for slide

a - Normalizing a Data Model

  1. 1. Instructor : Dimara Kusuma Hakim, ST.
  2. 2. What Is Normalization? <ul><li>At its most basic level, normalization is the process of simplifying your data into its most efficient form by eliminating redundant data. </li></ul><ul><li>Efficiency, in this case, refers to reducing complexity from a logical standpoint. </li></ul><ul><li>Efficiency does not necessarily equal better performance, nor does it necessarily equate to efficient query processing. </li></ul>
  3. 3. Normal Forms <ul><li>E. F. Codd, who was the IBM researcher credited with the creation and evolution of the relational database, set forth a set of rules that define how data should be organized in a relational database. Initially, he proposed three sequential forms to classify data in a database: </li></ul><ul><ul><li>first normal form (1NF) </li></ul></ul><ul><ul><li>second normal form (2NF) </li></ul></ul><ul><ul><li>third normal form (3NF). </li></ul></ul>
  4. 4. Normal Forms …cont… <ul><li>After these initial normal forms were developed, research indicated that they could result in update anomalies, so three additional forms were developed to deal with these issues: fourth normal form (4NF), fifth normal form (5NF), and the Boyce-Codd normal form (BCNF). There has been research into a sixth normal form (6NF); this normal form has to do with temporal databases and is outside the scope of this discussion. </li></ul>
  5. 6. Ketergantungan Fungsional <ul><li>Atribut Y pada relasi R dikatakan tergantung fungsional pada atribut X (R.X ---> R.Y), jika dan hanya jika setiap nilai X pada relasi R mempunyai tepat satu nilai Y pada R. </li></ul>
  6. 7. Ketergantungan Fungsional Penuh <ul><li>Atribut Y pada relasi R dikatakan tergantung fungsional penuh pada atribut X pada relasi R, jika Y tidak tergantung pada subset dari X ( bila X adalah key gabungan) </li></ul><ul><li>Atau jika Y tergantung pada X (suatu gabungan beberapa atribut) </li></ul>
  7. 8. Ketergantungan Transitif / Ganda <ul><li>Atribut Z pada relasi R dikatakan tergantung transitif pada atribut X , jika atribut Y tergantung pada atribut X pada relasi R dan atribut Z tergantung pada atribut Y pada relasi R. ( X Y, Y Z , maka X Z ) </li></ul>
  8. 9. Tabel KIRIM-1 (Unnormal)
  9. 10. First Normal Form (1NF) <ul><li>Suatu relasi dikatakan sudah memenuhi Bentuk Normal Kesatu bila setiap data bersifat atomik yaitu setiap irisan baris dan kolom hanya mempunyai satu nilai data </li></ul>
  10. 11. Tabel KIRIM-2 (1NF)
  11. 12. Second Normal Form (2NF) <ul><li>Suatu relasi dikatakan sudah memenuhi Bentuk Normal Kedua bila relasi tersebut sudah memenuhi bentuk Normal kesatu, dan atribut yang bukan key sudah tergantung penuh terhadap key-nya. </li></ul>
  12. 15. Third Normal Form (3NF) <ul><li>Suatu relasi dikatakan sudah memenuhi Bentuk Normal ketiga bila relasi tersebut sudah memenuhi bentuk Normal kedua dan atribut yang bukan key tidak tergantung transitif terhadap keynya. </li></ul>
  13. 17. NORMALIZATION VS. DENORMALIZATION <ul><li>Normalization means reducing duplicate data by using keys or IDs to relate rows of information from one table to another, for example, customers and their orders. </li></ul><ul><li>Denormalization means the opposite, which is deliberately duplicating data in one or more structures. </li></ul>
  14. 18. Cont…. NORMALIZATION VS. DENORMALIZATION <ul><li>Normalization improves the efficiency of inserting, updating, or deleting data. The fewer places the data has to be updated, the more efficient the update and the greater the data integrity. </li></ul><ul><li>Denormalization improves the efficiency of reading or selecting data and reduces the number of tables the data engine has to access or the number of calculations it has to perform to provide information. </li></ul>

×