From: | Reece Hart <reece(at)harts(dot)net> |
---|---|
To: | Jeff Davis <pgsql(at)j-davis(dot)com> |
Cc: | Talha Khan <talha(dot)amjad(at)gmail(dot)com>, pgsql-general <pgsql-general(at)postgresql(dot)org> |
Subject: | Re: database name aliases? |
Date: | 2006-11-07 03:58:04 |
Message-ID: | 1162871884.4770.23.camel@snafu.site |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
On Mon, 2006-11-06 at 16:43 -0800, Jeff Davis wrote:
> You can use "ALTER DATABASE name RENAME TO newname;". Does that help?
This is what I do now to evolve from development to staging to
production, as well as to deprecate versions. That indeed solves most of
the problem.
Aliases might solve two problems. The first is to address the
oft-recurring problem of wanting to be able to refer simultaneously to
an instance and more generally to a concept (e.g., HEAD in cvs,
or /etc/alternatives/ for system executables, etc). That is, one could
refer to a specific db version/instance as well as a name for the "most
recent" version (or dev, stage, prod, or whatever).
The second goal is more practical: postgres doesn't allow a database to
be renamed while it's in use and that prohibition causes minor
scheduling problems when rotating instances. I imagine that db aliases
would affect only new connections.
Thanks,
Reece
--
Reece Hart, http://harts.net/reece/, GPG:0x25EC91A0
From | Date | Subject | |
---|---|---|---|
Next Message | Adrian Klaver | 2006-11-07 04:29:10 | Re: R and postgres |
Previous Message | Reece Hart | 2006-11-07 03:38:37 | Re: R and postgres |