Q
Get started Bring yourself up to speed with our introductory content.

Using REUSEDLT on physical files

Should I always use REUSEDLT (re-use deleted records) on my physical files?


When a record is deleted, it still holds up space. It is flagged as deleted. The default for a physical file is to leave such records in place and not to use their space when writing new records. This may lead to files full of deleted records and wasted space on the system. The solution then is to reorganize the files. This will release space.

But reorganizing a very large file or a file that is constantly in use is near to impossible. This is where the possibility to make the file re-use space left by deleted records comes handy. There are a few circumstances where re-use delete is not suitable. If you have a file in which record order matters, you can not use re-use delete, as your records would be mixed up. If you have keys, either physical or logical, that use FIFO, LIFO and so on, you will not be able to change your file to re-use deleted records. But I do not think that such file uses should be found in a modern database.

In the first case, you may use a sequence field or a time-stamp field that will be used in an access path to make sure you read your records in order. In the second case, you may add a time-stamp field that will record the time the record was created (for FIFO and LIFO) or the time the record was modified (for FCFO). You would simply modify your access path by adding the time stamp in the last key position, and you would be able to use re-use deleted records.


This was last published in February 2001

Dig Deeper on iSeries SQL commands and statements

Have a question for an expert?

Please add a title for your question

Get answers from a TechTarget expert on whatever's puzzling you.

You will be able to add details on the next page.

Start the conversation

Send me notifications when other members comment.

Please create a username to comment.

-ADS BY GOOGLE

SearchDataCenter

  • How do I size a UPS unit?

    Your data center UPS sizing needs are dependent on a variety of factors. Develop configurations and determine the estimated UPS ...

  • How to enhance FTP server security

    If you still use FTP servers in your organization, use IP address whitelists, login restrictions and data encryption -- and just ...

  • 3 ways to approach cloud bursting

    With different cloud bursting techniques and tools from Amazon, Zerto, VMware and Oracle, admins can bolster cloud connections ...

Close