| From: | Gary Chambers <gwchamb(at)gwcmail(dot)com> |
|---|---|
| To: | Marti Raudsepp <marti(at)juffo(dot)org> |
| Cc: | martin(at)gregorie(dot)org, pgsql-general(at)postgresql(dot)org |
| Subject: | Re: Fixing the loss of 'template1' |
| Date: | 2012-03-07 14:53:56 |
| Message-ID: | alpine.OSX.2.01.1203070946100.2542@localhost |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-general |
Marti,
> As far as I can tell, the only way to remove the template1 database is to
> rename it.
Templates are databases with the datistemplate column set to true. A
superuser can:
UPDATE pg_database SET datistemplate=false where datname='blah';
DROP DATABASE blah;
As far as Pg is concerned, there is no problem with removing the template1
or postgres databases. That is not (or may not be) the case for some
utilities and Linux distributions out there that expect them to exist where
used as defaults. I haven't yet tried removing template0.
--
Gary Chambers
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Andy Colson | 2012-03-07 15:09:38 | rounding a timestamp to nearest x seconds |
| Previous Message | Marti Raudsepp | 2012-03-07 14:43:53 | Re: Fixing the loss of 'template1' |