Re: How to drop all the sequences

Поиск
Список
Период
Сортировка
Искать
От
Neil Conway
Тема
Re: How to drop all the sequences
Дата
Msg-id
1045809773.583.438.camel@tokyo
Ответ на
How to drop all the sequences (Arunachalam Jaisankar)
Список
Дерево обсуждения
How to drop all the sequences "Arunachalam Jaisankar" <arun_jaisankar@yahoo.com>
Re: How to drop all the sequences Neil Conway <neilc@samurai.com>
Re: How to drop all the sequences Bruce Momjian <pgman@candle.pha.pa.us>
Re: How to drop all the sequences "Berend Tober" <btober@seaworthysys.com>
On Thu, 2003-02-20 at 11:40, Arunachalam Jaisankar wrote:
> I found sequences are not getting dropped when tables are dropped.

SERIAL sequences should automatically be dropped with their
corresponding table in PostgreSQL 7.3.0 and later.

> It is too difficult to drop all sequences one by one manually. Is
> there any command to drop all sequences in a database? 

No. You could try iterating through pg_class, picking out the sequence
relations (relkind = 'S') in the right database, and then dropping the
sequences that way.

Cheers,

Neil
-- 
Neil Conway  || PGP Key ID: DB3C29FC



В списке pgsql-general по дате отправления
От: Neil Conway
Дата:
От: Neil Conway
Дата:
FAQ