christianbundy
christianbundy

Reputation: 674

Why shouldn't PostGIS be installed in the PostgreSQL database "postgres"?

The PostGIS installation documentation reads:

PostGIS is an optional extension that must be enabled in each database you want to use it in before you can use it. Installing the software is just the first step. DO NOT INSTALL it in the database called postgres.

We're running PostgreSQL in Docker and only need one database, so we've been using the default database, postgres. My first inclination was to install PostGIS there, but the documentation seems pretty clear that we shouldn't be doing that.

Is there a reason for PostGIS not to be installed on the default database, or is this note meant to deter people from accidentally installing PostGIS in the postgres database when their data is in the foobar database?

Thanks!

Upvotes: 8

Views: 765

Answers (1)

Peter Eisentraut
Peter Eisentraut

Reputation: 36729

There is no danger in installing PostGIS into the postgres database. The note is just so users don't confuse themselves, as you suspected.

Upvotes: 8

Related Questions