Q on requirement to connect to a specific DB

From: <kynn(at)panix(dot)com>
To: pgsql-novice(at)postgresql(dot)org
Subject: Q on requirement to connect to a specific DB
Date: 2006-05-14 19:41:01
Message-ID: 200605141941.k4EJf1u03893@panix3.panix.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-novice

As far as I understand, one always has to connect to a specific
database even when what one wants to do does not have anything to do
with any existing database. For example, suppose I just want to
create a new database. As far as I know I must connect to *some*
database, whose role is irrelevant, just so that I can execute "CREATE
DATABASE ..." from that connection.

I find this puzzling from a design perspective. Why involve some
irrelevant DB in the process of creating a new one? Am I
understanding the whole situation correctly? If so, what is the
"canonical" database to connect to? (Is this the purpose of
"template1"?)

Thanks!

kj

Responses

Browse pgsql-novice by date

  From Date Subject
Next Message Sean Davis 2006-05-15 00:40:57 Re: Q on requirement to connect to a specific DB
Previous Message Sean Davis 2006-05-13 01:22:33 Re: Query Formulation Question