For IT professionals, you’ve heard of the concept of a database. As the name implies, a database system is the software that manages data storage. This paper summarizes the database system knowledge related to software grade examination as a whole, which is convenient for everyone to review.

1. Type of the database management system

There are different classification methods for database systems (see figure below). Most modern database systems are multi-user and distributed, so the most important difference lies in the data model adopted. For relational databases are more famous Mysql, Oracle, for hierarchical database typical IMS, as well as graph database and other types of database.

2. Database schema and paradigm

2. A pattern:

2.1 Database structure and mode

The database structure is divided into several levels, the most famous is the ANSI/SPARC Database System research group in 1975 proposed the three-level division method.

This part is tested almost every year.

2.1.1 Tertiary abstraction

There are three levels of abstraction: user level, conceptual level, and physical level.

  • User-level: corresponds to the external mode and is closest to the user. It is also called the user view.
  • Conceptual level: corresponds to the conceptual mode and is the minimum union of all user views. It is the database that the database administrator sees and uses.
  • Physical: describes the actual storage organization of data corresponding to the internal mode, also called the internal view.Physical level databases are not really physical storage, but the closest level to physical storage.

2.1.2 Three-level mode

The three modes are conceptual mode, external mode and internal mode.

  • Conceptual schema: also called schema, logical schema, describes the logical structure of the database, describes the entities in the real world and their properties and connections, is the framework of data item value. It is the description of the logical structure and characteristics of all the data in the database, and it is the common data attempt of all users. A database has only one conceptual schema.
  • External mode: describes the logical structure in which users view and use part of the data. Users operate data with DML statements according to the external mode. A database can have multiple external schemas, and an application can use only one external schema.
  • Internal mode: defines the types of records to be stored, storage domains, and the physical order in which records are stored. A database has only one internal schema.

2.1.3 Independence of the two levels

  • Physical independence: The application is independent of the physical storage of the database and does not need to change when the storage changes.
  • Logical independence: The logical structure of the application and database is independent of each other, and there are mapping transformations between external schema and conceptual schema.

2.2 Data Model

  • Conceptual data model: also called entity relation model E-R model. Model data and information from the user’s perspective for database design.

  • Basic data model: also called structural data model. According to the view of computer system to model the data and information for DBMS implementation. It is the core and foundation of database system, including data structure, data operation and integrity constraint.

    • Hierarchical model: Use a tree structure to represent entity types and relationships between entities. The advantage is that the query efficiency is high, but the disadvantage is that the m: N connection is complicated.
    • Mesh model: Use a directed graph to represent entity types and relationships between entities. Advantages high query efficiency, disadvantages of complex application programming.
    • Relational model: A table structure is used to represent entity sets, and foreign keys represent relationships between entities.
    • Object-oriented model

2.3 Data Normalization

According to the level of constraints, relational models can be divided into 1NF (first normal form), 2NF (second normal form), 3NF (third normal form), BCNF (BC normal form), and 4NF (fourth normal form) from low to high. The normalization process refers to the decomposition of a lower-order relational model into a higher-order relational model, which must follow two principles: 1. Lossless connectivity and no distortion of information (increase or decrease); 2. 2, function dependency maintenance, do not destroy the dependency between attributes.

  • 1NF: Minimum standardization requirements. To achieve elements (attributes) can not be divided, is a database design must achieve.
  • 2NF: If all non-main attributes are completely dependent on the main attributes, it is called the second normal form.
  • 3NF: belongs to the second normal form, and each non-primary attribute is not transitive dependent on the primary attribute.
  • BCNF: Improvement of the third normal form, less test. Complete functions without attributes depend on a set of non-primary attributes.
  • 4 nf:

Standardized design will lead to performance degradation, and the level of data specification should be determined according to the actual situation in practical work. Sometimes they de-normalize, using more space in exchange for more efficient execution.

Welcome to pay attention to me, learn more about the soft test related content. I will accompany you to prepare for the review of software grade examination, and also share some Internet technology information from time to time to grow together with you.