Add database comments to template0 and postgres databases, and improve
authorBruce Momjian <[email protected]>
Tue, 15 Mar 2011 15:26:20 +0000 (11:26 -0400)
committerBruce Momjian <[email protected]>
Tue, 15 Mar 2011 15:26:57 +0000 (11:26 -0400)
the comments on the template1 database.  No catalog version bump because
they are just comments.

src/bin/initdb/initdb.c
src/include/catalog/pg_database.h

index f6cf37728223938233c4f8c8cb25de374834d6a2..7a4b698b99fe327d2fe815d965686f8b8d29987c 100644 (file)
@@ -1976,6 +1976,8 @@ make_template0(void)
                "REVOKE CREATE,TEMPORARY ON DATABASE template1 FROM public;\n",
                "REVOKE CREATE,TEMPORARY ON DATABASE template0 FROM public;\n",
 
+               "COMMENT ON DATABASE template0 IS 'unmodifiable empty database';\n",
+
                /*
                 * Finally vacuum to clean up dead rows in pg_database
                 */
@@ -2011,6 +2013,7 @@ make_postgres(void)
        const char **line;
        static const char *postgres_setup[] = {
                "CREATE DATABASE postgres;\n",
+               "COMMENT ON DATABASE postgres IS 'default administrative connection database';\n",
                NULL
        };
 
index 6419d656827e765d5a5cf169ef5d4a9a17622a8d..ee4c8582afe4190b297298ae5f665b864e81161d 100644 (file)
@@ -71,7 +71,7 @@ typedef FormData_pg_database *Form_pg_database;
 #define Anum_pg_database_datacl                        12
 
 DATA(insert OID = 1 (  template1 PGUID ENCODING "LC_COLLATE" "LC_CTYPE" t t -1 0 0 1663 _null_));
-SHDESCR("default template database");
+SHDESCR("default template for new databases");
 #define TemplateDbOid                  1
 
 #endif   /* PG_DATABASE_H */