The simplest explanation of the three major database paradigms

Source: Internet
Author: User

The relationships in relational databases must meet certain requirements, that is, they must meet different paradigms. Currently, relational databases have six paradigms: 1NF, 2NF, 3NF, 4NF, and 5NF) and the sixth paradigm (6NF ). The first paradigm (1NF) meets the minimum requirements ). The second Paradigm (2NF) that meets more requirements on the basis of the first paradigm, and the other paradigms are similar. Generally, databases only need to satisfy the 3NF.

The paradigm mentioned in many documents is hard to understand. Here, we will summarize the three paradigms for readers to easily understand.

1NF: fields are atomic and cannot be divided;
2NF: primary key exists. non-primary key fields depend on the primary key. Make sure that a table only describes one thing
3NF: non-primary key fields cannot depend on each other. Each column has a direct relationship with the primary key, and there is no dependency for passing.

Example of the first paradigm:

Table: Field 1, Field 2 (field 2.1, field 2.2), Field 3 ......

Example of the second paradigm:

Table: Student ID, course number, name, and credits;

This table clearly shows two transactions: Student Information and course information. Because the non-primary key field must depend on the primary key, the credits here depend on the course number, and the name depends on the student number, it does not conform to the second paradigm.

Third paradigm: examples that do not conform to the third paradigm:

Table: Student ID, name, age, school, school contact number, school contact number

Dependent transmission: (student ID) → (school location, school phone number)



Related Article

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.