In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-03-31 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Database >
Share
Shulou(Shulou.com)05/31 Report--
What this article shares to you is about how to allocate the space of database files. The editor thinks it is very practical, so I share it with you. I hope you can get something after reading this article. Let's take a look at it with the editor.
The SQL Server log file consists of a series of log records; the database file is divided into different pages and areas.
(1) Page is the basic unit in which SQL server stores data. According to the different information stored on the page, it can be divided into the following six categories.
1. Data page: stores data in data rows except text, ntext, and image column data.
2, text / image page: stores text, ntext, and image column data in the data row.
3. Index Zhengmian: store index items.
4. Global allocation mapping page: stores the area allocation information of the data file.
5, free space page drawing: store data files from available blank page information.
6. Index allocation mapping page: stores the area information used by the table or index.
The size of each page is 8KB, that is, 8192 bytes, and the first 96 bytes are page headers, which are used to store system information such as page type information, free storage in the page and object identification that occupies the face. Each virgin can contain at least one row in the table, and a single row cannot exceed the length of the page. Only one table of data can be stored per page because it also belongs to a specific table. When space is needed, in order to avoid greatly increasing the system overhead by allocating many individual pages, the space is divided into many units, which are called areas.
(2) the area is the smallest unit that SQL Server can allocate each time it applies for space, which is 8 consecutive pages, that is, 64KB. To save space in the database, each object in the library is not assigned a complete area, but uses two different regions:
Mixed type. Pages in a mixed area can form eight different objects.
Unified type. All pages in a unified area must belong to the same object.
When an object is created each time, SQL server allocates space for it in a mixed area. If this object is increased to contain 8 pages or more, SQL server will move the existing database to a system-type area.
The above is how to allocate the space of database files, and the editor believes that there are some knowledge points that we may see or use in our daily work. I hope you can learn more from this article. For more details, please follow the industry information channel.
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 207
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.