Re: Fwd: Identify system databases - Mailing list pgsql-general

From Laurenz Albe
Subject Re: Fwd: Identify system databases
Date
Msg-id f5612b59b0a82bee2bf28efd314ac338bbc4c6b5.camel@cybertec.at
Whole thread Raw
In response to Re: Fwd: Identify system databases  (Adrian Klaver <adrian.klaver@aklaver.com>)
Responses Re: Fwd: Identify system databases
List pgsql-general
On Tue, 2025-04-15 at 17:24 -0700, Adrian Klaver wrote:
> I know I can use --template=template with createdb, but that still means
> there has to be a database existing in the initial cluster to use as a
> template. You can't get around that fact.

Right.

But then you fortunately cannot drop all databases, because you cannot
drop the database you are connected to.

Still, a cluster that is missing "postgres" will give beginners trouble,
a cluster that is missing "template1" is annoying, and a cluster without
"template0" is possibly in serious trouble.

Yours,
Laurenz Albe



pgsql-general by date:

Previous
From: vijay patil
Date:
Subject: Re: Best Tool for PostgreSQL Auditing and Storing Audit Logs Separately
Next
From: Dominique Devienne
Date:
Subject: Re: Fwd: Identify system databases