Re: Toasted table not deleted when no out of line columns left

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: Toasted table not deleted when no out of line columns left
Дата
Msg-id 16699.1222221516@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: Toasted table not deleted when no out of line columns left  (Hannu Krosing <hannu@krosing.net>)
Список pgsql-hackers
Hannu Krosing <hannu@krosing.net> writes:
> On Sun, 2008-09-21 at 12:05 -0400, Tom Lane wrote:
>> The DROP COLUMN form does not physically remove the column, but
>> simply makes it invisible to SQL operations. Subsequent insert and
>> update operations in the table will store a null value for the
>> column. Thus, dropping a column is quick but it will not immediately
>> reduce the on-disk size of your table, as the space occupied by the
>> dropped column is not reclaimed. The space will be reclaimed over
>> time as existing rows are updated.

> And it seems that it is never reclaimed (instead of "reclaimed over
> time" as claimed in docs) if the column happens to have been toasted.

Utterly false.  The toasted values will be deletable after their parent
rows have been updated.  This is exactly the same as for space in the
parent row itself.

> how do you explain the above "VACUUM [FULL] [ANALYZE] didn't cleaned up
> the space" claim ?

He didn't do any updates in the parent table.
        regards, tom lane


В списке pgsql-hackers по дате отправления:

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: 0x1A in control file on Windows
Следующее
От: Tom Lane
Дата:
Сообщение: Re: pg_type.h regression?