| From: | Sevo Stille <sevo(at)ip23(dot)net> | 
|---|---|
| To: | Patrick Robin <Patrick(dot)Robin(at)disney(dot)com> | 
| Cc: | pgsql-general(at)postgresql(dot)org | 
| Subject: | Re: Renaming database | 
| Date: | 2000-08-18 14:07:21 | 
| Message-ID: | 399D4319.1E69848C@ip23.net | 
| Views: | Whole Thread | Raw Message | Download mbox | Resend email | 
| Thread: | |
| Lists: | pgsql-general | 
Patrick Robin wrote:
> 
> What is the best way to rename a database in Postgres 6.5.
The only documented way is dump and restore.
> Will moving the unix directory work?
No. Moving the directory and updating datname and datpath in pg_database
will. Caveat: In that, you'll inevitably have some period where your
configuration is hosed. Less likely to go wrong would be keeping the old
directory name and only updating datname. YMMV - live surgery on
databases can be useful in emergencies, but it has risks. The only
guaranteed safe procedure is dump and restore!
Sevo
-- 
sevo(at)ip23(dot)net
| From | Date | Subject | |
|---|---|---|---|
| Next Message | David Shrewsbury | 2000-08-18 15:47:19 | vacuum messages | 
| Previous Message | Grembowicz, Kenneth | 2000-08-18 13:55:09 | VERY SLOW UPDATES |