I\'m using PostgreSql version :
postgres=# select version();
version
-------------------------------------------------------------
P
There is not a 'disconnect' in psql. Instead of disconnecting from your newdb database you connect with the default postgres database.
Create the new database and connect to it:
postgres=# create database newdb;
CREATE DATABASE
postgres=# \c newdb
You are now connected to database "newdb" as user "postgres".
newdb=#
List the number of connections on newdb:
newdb=# select datname,numbackends from pg_stat_database where datname='newdb';
datname | numbackends
---------+-------------
newdb | 1
Now, instead of disconnecting, just connect with the default postgres database.
newdb=# \c postgres
You are now connected to database "postgres" as user "postgres".
postgres=#
Now there are no connections on newdb:
postgres=# select datname,numbackends from pg_stat_database where datname='newdb';
datname | numbackends
---------+-------------
newdb | 0