Re: Feature Request: DROP ALL FROM DATABASE database_name

Поиск
Список
Период
Сортировка
От Thomas Swan
Тема Re: Feature Request: DROP ALL FROM DATABASE database_name
Дата
Msg-id 3C3B876E.7000804@ics.olemiss.edu
обсуждение исходный текст
Ответ на Re: Feature Request: DROP ALL FROM DATABASE database_name  (Bruce Momjian <pgman@candle.pha.pa.us>)
Список pgsql-hackers
Bruce Momjian wrote:<br /><blockquote cite="mid:200201082333.g08NXuo16483@candle.pha.pa.us" type="cite"><pre
wrap="">ThomasSwan wrote:<br /></pre><blockquote type="cite"><pre wrap="">This could be useful for cleaning out a
database(sequences, triggers, <br />rules) without deleting it and without having to create it, thus <br />preserving
permissions/ownerinformation.<br /></pre></blockquote><pre wrap=""><br />Why delete just those?  I don't see a
compellingusefulness.<br /><br /></pre></blockquote> You have to explicitly name all of them.   Also, some of those are
unnamedif they were auto created.  <br /><br /> Also, the SERIAL datatype creates an auto_named sequence that's not
alwayseasy to figure out.    And, dropping a table leaves that sequence still intact. <br /><br /> On the owner
permissionsfront.    If someone is developing and wants to wipe their database and start fresh,  the easiest way is to
doa drop database, and create database.   But, that would require the createdatabase right.    But, in a situation
wheremultiple developers are working on different databases, this is awkward.     The proposed request always a normal
userto clean that database and start fresh, so to speak.<br /><br /> 

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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: Feature Request: DROP ALL FROM DATABASE database_name
Следующее
От: Tom Lane
Дата:
Сообщение: Re: ECPG warning