First paradigm, second paradigm, and third paradigm

Source: Internet
Author: User
First paradigm, second paradigm, third paradigm, first paradigm

If all the attributes of a relational model R are basic data items that cannot be divided, then R is 1nf (that is, r conforms to the first paradigm ).

Two points:

1. Each field can only store a single value


The course has two values, which do not conform to the first paradigm and can be changed as follows:



2. Each record must be identified by a unique primary key.


Duplicate groups appear here, which also does not meet the first paradigm. Because of the lack of a unique identifier code, you can change it



Second paradigm

If the relational model rε 1nf (that is, r conforms to the first paradigm) and every non-primary attribute is completely dependent on the R code, rε 2nf (that is, r conforms to the second paradigm ).



The table code here is (student ID, course). You can determine the system name, dormitory, and score, or the three items depend on the first two items.

  • Full dependence on scores (student ID, course)
  • The system name depends on (student ID, course), that is, the system name can be determined by knowing the student ID or course.
  • Part of the dormitory building depends on (student ID, course), that is, the dormitory building can be determined by knowing the student ID or course.

Because the non-primary attribute is named, the dormitory building is not completely dependent on and code, and does not conform to the second paradigm. You can change it

Table 1




Third paradigm

If the relational mode rε 3nf (that is, r conforms to the third paradigm), neither the Code nor the code is partially dependent on each non-primary attribute.



The above table 2 does not conform to the third paradigm. This is because you know the system name, and you also know the dormitory building. The dormitory building transmission relies on code (student ID) and can be divided









First paradigm, second paradigm, and third paradigm

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.