1.2.3 workflow of the Database System
A database system generally consists of a database, a database management system (and its development tools), an application system, a database administrator, and a user. The following describes how to query a group of data in a database, as shown in Figure 1.7.
The DBMS first checks the syntax of the data query statement, then finds the external mode corresponding to the user from the data dictionary, and checks the permissions at the same time. If an error is found, the error message is returned to the user.
Based on the external mode, DBMS uses the conceptual mode/external mode image to map it to the conceptual mode to determine what data should be read in the conceptual mode.
|
Figure 1.7 workflow diagram of the Database System |
DBMS uses the internal mode/conceptual mode image to map the conceptual mode to the internal mode to determine which physical records and their specific addresses should be read by the database.
DBMS sends a command to the operating system to read records based on the address information.
The operating system executes the command to read data, reads data from the hard disk into the system buffer, and notifies the DBMS of the execution result.
DBMS converts the data in the system buffer into the record format required by the user based on the query statement and the information defined in the data dictionary.
DBMS transfers data records from the system buffer to the user workspace.
It can be seen that the database management system is in the central position in the database system.
DBMS does not directly read data from the database, but accesses the database through the operating system. The database system is based on the operating system.