What is the three-level schema structure of a database system?
The three-level schema structure of the database system means that the database system consists of three levels: external schema, schema and internal schema. The schema, also called the logical schema, is the common data view for all users; the external schema, also called the user schema, is the data view of database users and is a logical representation of data related to an application; the internal schema, also called the storage schema, is the data within the database. of organization.
The operating environment of this tutorial: windows7 system, mysql8 version, Dell G3 computer.
The three-level schema structure of the database system:
The three-level schema structure of the database system means that the database system is composed of external schema, schema and The internal schema is composed of three levels, as shown in the figure:
① Schema:
Schema is also called logical schema , is a description of the logical structure and characteristics of all data in the database, and is a public data view for all users. It is the middle layer of the database system schema structure. It does not involve the physical storage details of data, and has nothing to do with specific applications, application development tools and high-level programming languages used.
Schema is actually a logical view of database data. A database has only one schema. The database schema is based on a certain data model, comprehensively considers the needs of all users, and organically combines these needs into a logical whole. When defining a schema, it is not only necessary to define the logical structure of the data, such as which data items the data record consists of, the names, types, value ranges of the data items, etc.; it is also necessary to define the connection between the data, and define the security and integrity of the data. sexual requirements.
The database management system provides schema data definition language (schema DDL) to strictly define the schema.
②External schema (external schema):
External schema is also called subschema (subschema) or user schema. It is the database used for firmware. The description of the logical structure and characteristics of the local data that can be seen and used by (including application programmers and end users) is the data view of the database user and the logical representation of the data related to a certain application.
Foreign patterns are usually a subset of patterns. A database can have multiple foreign schemas. Since it is the data view of each user, if different users have differences in application requirements, ways of viewing data, and requirements for data confidentiality, their external schema descriptions will be different. Even for the same data in the schema, the structure, type, length, confidentiality level, etc. of the external schema can be different. On the other hand, the same foreign mode can also be used by multiple application systems of a certain user, but an application can only use one foreign mode. Foreign mode is a powerful measure to ensure database security. Each user can only see and access the data in the corresponding foreign schema, and the rest of the data in the database is invisible.③Internal schema:
Internal schema is also called storage schema. A database has only one internal schema. It is a description of how data is physically stored and stored, and how data is organized within the database. For example, whether the record storage method is heap storage, storage in ascending (descending) order of a certain attribute value(s), or cluster storage according to attribute values; in what way the index is organized, it is a B-tree index Or hash index; whether the data is compressed and stored, whether it is encrypted; what are the regulations for the storage record structure of the data, such as fixed-length structure or variable-length structure, a record cannot be stored across physical pages; etc.
(Recommended tutorial:mysql video tutorial)
The above is the detailed content of What is the three-level schema structure of a database system?. For more information, please follow other related articles on the PHP Chinese website!

Hot AI Tools

Undresser.AI Undress
AI-powered app for creating realistic nude photos

AI Clothes Remover
Online AI tool for removing clothes from photos.

Undress AI Tool
Undress images for free

Clothoff.io
AI clothes remover

AI Hentai Generator
Generate AI Hentai for free.

Hot Article

Hot Tools

Notepad++7.3.1
Easy-to-use and free code editor

SublimeText3 Chinese version
Chinese version, very easy to use

Zend Studio 13.0.1
Powerful PHP integrated development environment

Dreamweaver CS6
Visual web development tools

SublimeText3 Mac version
God-level code editing software (SublimeText3)

Hot Topics



The three-level schema structure of the database system means that the database system consists of three levels: external schema, schema and internal schema. The schema, also called the logical schema, is the common data view for all users; the external schema, also called the user schema, is the data view of database users and is a logical representation of data related to an application; the internal schema, also called the storage schema, is the data within the database. of organization.

Redis: a key technology for building high-availability database systems. With the development of the Internet and the advent of the big data era, the need for high-availability database systems has become increasingly urgent. As an in-memory storage NoSQL database system, Redis has become one of the key technologies for building high-availability database systems with its excellent performance and flexible data model. This article will delve into the high availability technology of Redis and demonstrate it with specific code examples. 1. The high availability requirements of Redis in actual applications

The relationship between database, database system and database management system is: database system includes database and database management system. A database system is a computer system with a database, which generally consists of a database, a database management system (and its development tools), related hardware, software and various personnel.

The core of the database system is the database management system (DBMS), which is system software that works with the support of the operating system and solves how to organize and store data scientifically, and how to obtain and maintain data efficiently; DBMS can perform unified management and management of the database. controls to ensure the security and integrity of the database.

The structure of database management systems is mostly "relational structure". The relationship structure is an unformatted structure that uses a single two-dimensional table structure to represent entities and the relationships between entities. The relational structure organizes data in the form of record groups or data tables to facilitate storage and transformation using the relationships between various entities and attributes. It does not have hierarchies or pointers. It is a way to establish the relationship between spatial data and attribute data. Very efficient way to organize data.

The core of the database system consists of the following elements: 1. Database; 2. Database management system; 3. Data model; 4. Database query language; 5. Database management tools; 6. Database applications.

Database system is a system composed of database and its management software. It is an ideal data processing system developed to meet the needs of data processing. It is also a software that provides data for actual operational storage, maintenance and application systems. A system is a collection of storage media, processing objects, and management systems.

The characteristics of the database system are data sharing and centralized management, data independence, data consistency and integrity, data security and permission control, efficient data access and query, scalability and scalability, and data backup and recovery. Detailed introduction: 1. The database system can centrally manage and store a large amount of data, and different users can share the same data, avoiding the problems of data redundancy and data inconsistency; 2. The database system realizes the separation of data and applications, and the physical separation of data Storage and logical representation are abstracted into database models and so on.