The only way to give the space from empty index pages back to the OS is
through manual compression.  Algorithms exist to reuse the empty index
and base table pages within the same table or index.

�ystein Gr�vlen wrote:
"TW" == The Wogster <[EMAIL PROTECTED]> writes:


    TW> �ystein Gr�vlen wrote:

    >> Is this also true for B-tree indexes?  I would imagine that if you
    >> have a index on a monotocally increasing key (e.g., a timestamp) and
    >> where you regularly delete old records, there may be a lot of empty
    >> B-tree pages that will never be possible to reuse.
>>

    TW> What happens in most databases. is  that the database has a fixed page
    TW> size, say 8K, when  an index page is full, it splits  that page into 2
    TW> half pages. When an index page  is empty it's dropped from the index,
    TW> and  added to  the  empty page  pool.  Many will  merge almost  empty
    TW> neighbouring pages, but that doesn't matter for this discussion.

I know this.  The reason I asked was because I have got the impression
that in Derby the only way to drop empty index pages is to do
compression.


Reply via email to