Обсуждение: REINDEX or DROP and CREATE ?

Поиск
Список
Период
Сортировка

REINDEX or DROP and CREATE ?

От
"Gaetano Mendola"
Дата:
Hi all,
what the difference ( apart a windows without index ) between
REINDEX a TABLE
or
DROP each index and CREATE it again?

I'm worried about the type of locks involved.


Regards
Gaetano Mendola


Re: REINDEX or DROP and CREATE ?

От
Tom Lane
Дата:
"Gaetano Mendola" <mendola@bigfoot.com> writes:
> what the difference ( apart a windows without index ) between
> REINDEX a TABLE
> or DROP each index and CREATE it again?

Not much.

> I'm worried about the type of locks involved.

I'm pretty sure either course will take an exclusive lock on the table.

            regards, tom lane