Database design generally satisfies the third paradigm. The first paradigm (no duplicate columns) is defined: Each column of a database table is an indivisible atomic data item, not a collection, an array, a record, and other non-atomic data items. If an attribute in an entity has multiple values, it must be split into different properties popular explanation: A field stores only one information eg: class: High three years 1 classes, should be changed to 2 fields, a grade, a class, to meet the first paradigm does not meet the first paradigm
School Number |
Name |
Class |
0001 |
Little Red |
High three years, 1 classes |
Change into
School Number |
Name |
Grade |
Class |
0001 |
Little Red |
Three years high |
Class 1 |
The second paradigm (the property is completely dependent on the primary key) definition: satisfies the first paradigm premise, when there are more than one primary key, the situation that does not conform to the second normal form occurs. For example, there are two primary keys, there is no such attribute, it only depends on one of the primary keys, which is not in accordance with the second normal mode popular interpretation: any one field is dependent on the same field in the table eg: not conforming to the second normal
Name of student ID |
Student ID Number |
Student Card processing Time |
Name of library card |
Library card number |
Library card processing Time |
|
|
|
|
|
|
Change to 2 sheets as follows Student ID card form
Student ID |
Student ID Number |
Student Card processing Time |
|
|
|
Library Card Form
Borrowing documentary |
Library card number |
The library card pulls you to the time |
|
|
|
The third paradigm (property cannot be passed dependent on the main attribute) definition: satisfies the second paradigm premise, if a property relies on other non-primary key attributes, and the other non-primary key attributes depend on the primary key, then this property is indirectly dependent on the primary key, which is known as passing dependent on the primary property. Popular understanding: A table with up to 2 layers of the same type information eg: Dad table, not meet the third paradigm
Father |
Son |
Daughter |
Little Bear of the daughter |
Daughter's SpongeBob SquarePants |
|
|
|
|
|
Change to dad information Sheet:
Daughter Information Sheet
Daughter |
Little Bear of the daughter |
Daughter's SpongeBob SquarePants |
|
|
|
Turn from: 22933021 summarize the first paradigm-the atomicity of a column: A column can contain only one property. Second normal form-the only command of a primary key: A table can have only one primary key and only command. Third Paradigm-direct command of the primary key: The primary key of the table must direct other attributes, not the other columns.
Database model design, first paradigm, second normal form, third paradigm simple example understanding