From: | Thomas Swan <tswan(at)olemiss(dot)edu> |
---|---|
To: | Thomas Swan <tswan(at)olemiss(dot)edu> |
Cc: | Josh Berkus <josh(at)agliodbs(dot)com>, pgsql-sql(at)postgresql(dot)org |
Subject: | Re: Cleaning up template 1 |
Date: | 2002-03-25 21:16:26 |
Message-ID: | 3C9F93AA.9010405@olemiss.edu |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-sql |
Thomas Swan wrote:
> Josh Berkus wrote:
>
>> Folks,
>>
>> Due to an accident with a script, I created about 200 objects in the
>> template1 database instead of the database for which they were
>> intended. I am now faced with either deleting each of these object
>> individually,
>> or dumping my whole postgresql installation and re-installing each
>> user database, one at a time.
>>
> If this is 7.2 you should be able to drop template1 and do create
> database template1 from template0.
> DROP DATABASE template1;
> CREATE DATABASE template1 WITH TEMPLATE=template0;
>
> Check first with another installation as I'm not too sure about the
> ramifications.
If you installed languages on template1 for defaults you will need to
recreate them for the new template1 database. I forgot template0 was
completely empty.
>
>
>>
>>
>> Can anyone suggest any shortcuts for fixing this problem?
>>
>> -Josh
>>
>> ---------------------------(end of broadcast)---------------------------
>> TIP 5: Have you checked our extensive FAQ?
>>
>> http://www.postgresql.org/users-lounge/docs/faq.html
>>
>
>
>
>
> ---------------------------(end of broadcast)---------------------------
> TIP 6: Have you searched our list archives?
>
> http://archives.postgresql.org
From | Date | Subject | |
---|---|---|---|
Next Message | Bruce Momjian | 2002-03-25 21:23:57 | Re: About EXECUTE in pl/pgsql |
Previous Message | Bruce Momjian | 2002-03-25 21:15:54 | Re: 16 parameter |