Unused space inside a Table
Answered: green (solid confidence) — Benjamin explained the extent/bitmap-page free-space reuse algorithm in detail and Dirk confirmed it matched what he expected.
Advisory only.
Posted in 2019
Topics: Storage & Space Management
When you delete records from a Table, the empty space is not released / free'ed up. My question is: If you now insert records again, will the unused space be used first, to add the new records, or will it be added "at the end of the table" (for lack of better words), and new extents be added (the table will still grow) ? IDS 12 AIX 7
I believe it will fill up the allocated extents first "at the end of the table". When it gets to the end of the extents currently allocated, the engine will scan the table's bitmap pages from the beginning looking for empty or partially full pages and use these up before a new extent is allocated. There is a slight complication in with tables with variable width columns (usually varchars) whereby a partially full page may have space for a shorter row and not a longer one. If the row is too long to fit, the engine will continue to scan the bitmap pages. Ben.
Awesome. Thank you. As I expected. :-) Thanks again