[ACCEPTED]-How do I change the maintenance database for Postgres?-pgadmin
You can change maintenance db from pgAdmin
but 4 you have to be disconnected from the database 3 engine to be able to do that.
First disconnect:
Then 2 in the database server properties:
Choose 1 the desired maintenance database:
You're not entirely clear on this, but do 4 you mean the "Maintenance DB" selection 3 in pgAdmin III?
Select the server in your 2 "object browser" pane; right click -> Properties
The 1 fifth field is "Maintenance DB"
Maintenance db field is read-only , you 4 can't change it.So you should keep your 3 server properties somewhere and create new 2 server with these properties and set maintenance 1 db "postgres". Now you are able to drop database.
The command line option is :
psql -U intelison -c "UPDATE pg_database SET datistemplate=false, datallowconn=true WHERE datname = '<your_database_name>'"
0
More Related questions
We use cookies to improve the performance of the site. By staying on our site, you agree to the terms of use of cookies.