| From: | Alvaro Herrera <alvherre(at)2ndquadrant(dot)com> |
|---|---|
| To: | Sven Delle <svdellepude(at)gmail(dot)com> |
| Cc: | pgsql-admin(at)lists(dot)postgresql(dot)org |
| Subject: | Re: How to rename current database? |
| Date: | 2018-05-09 13:03:30 |
| Message-ID: | 20180509130330.vu3gozt2mk7b6eb3@alvherre.pgsql |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-admin |
Sven Delle wrote:
> I’m going to the properties of the database to rename it, but get an
> error: ERROR: current database cannot be renamed.
>
> Hmm, I guess it’s because it’s currently running, fine – I get that.
> But then, HOW THE HOLY CRAP DO I STOP THE DATABASE SO I CAN RENAME
> IT!?!?!?!?!?!?!?!!?!!?!?
A PostgreSQL server (or "service") hosts multiple databases, and any one
session is connected to one database. What the message is saying is
that you can't rename the database you're connected to -- it is *not*
that you have to stop the server. In Postgres terminology, databases
cannot be "stopped"; servers can.
This applies to pgadmin just like to any other program you use to
connect to a database.
--
Álvaro Herrera https://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Alvaro Herrera | 2018-05-09 13:05:45 | Re: How do I execute SQL in pgAdmin!? |
| Previous Message | Scott Whitney | 2018-05-09 12:14:08 | Re: How to rename current database? |