Scalable Database Server, HiRDB Version 8 Installation and Design Guide
![[Contents]](FIGURE/CONTENT.GIF)
![[Index]](FIGURE/INDEX.GIF)
![[Back]](FIGURE/FRONT.GIF)
14.5.3 Effects and applicability
(1) Effects
The following effects can be expected with the use of this facility:
- Effective reuse of free space
By reusing the free space of used pages, operations can be performed using a minimum amount of RDAREA space, thereby minimizing the frequency of database reorganization. If multiple tables and indexes are stored in the same RDAREA, the insertions and deletions for some tables can be combined, such that occupied area can be recovered.
- Recovery from an insufficient pages error for variable-length columns and BINARY type columns
Normally, if the no-split option is not specified, unused pages are allocated whenever a variable-length character column of at least 256 bytes is inserted or a BINARY type column that does not fit on one page is inserted. Even if used free pages are available, an error will result if an unused page cannot be allocated. If the free space reusage facility is being used, however, errors can be avoided because used free pages will be allocated if no unused free pages are available.
- Reduction in overhead during a search for free space on used pages
In the free page reuse mode, high-speed processing is possible due to the reduced overhead because the search start position is remembered and is used for the subsequent search.
(2) Applicability
- If you have an application that performs frequent deletions or insertions, such that the amount of data results in use of a large number of segments and frequent need for reorganization, and you would like to minimize the number of reorganizations, you should use the free space reusage facility. This section describes the application characteristics and the circumstances under which this facility is recommended.
- When there is no increase in data volume, including deletions (updates) and insertions
If the maximum size of the data to be stored is specified with the free space reusage facility, the area from deleted data will later have priority for reuse. The application can then continue without having to add new area, so reorganization will not be necessary.
- Example: Electronic administrative window
- An application that receives data from an electronic window must be a 24-hour system. When an application is received, the data is inserted and later, once the storage period has passed, it is deleted. If the maximum segment size for the data to be received within the storage period is specified, then the space from deleted data can be reused. The application can then continue without having to add additional space. Reorganization then becomes unnecessary, the application will never need to stop, and it can provide 24-hour service.
- When there is a steady increase in data volume, including deletions (updates) and insertions
Steadily increasing data is stored not only in new space, but also in deleted space, increasing storage efficiency.
- Example: Customer management
- This application requires inserting new customer data, and deleting old customer data as it becomes no longer needed. Once the initial customer data has been entered in full, if the segment size is specified before starting a transaction to add or delete a customer, customer data added later will reuse the space from any deleted customer data.
- For insertion processing, performance is best if data is stored in unused pages and unused segments. Therefore, if the database reorganization utility (pdrorg) can be executed quickly, the free space reusage facility would not be appropriate, and database reorganization would provide better performance.
All Rights Reserved. Copyright (C) 2007, Hitachi, Ltd.