git.postgresql.org Git - postgresql.git/commitdiff

git projects / postgresql.git / commitdiff
? search:
summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 8c19977)
Add C comment
2011年4月19日 23:14:39 +0000 (19:14 -0400)
2011年4月19日 23:15:13 +0000 (19:15 -0400)
Add C comment about why we throw an error if the pg_upgrade old/new
database counts don't match.


diff --git a/contrib/pg_upgrade/relfilenode.c b/contrib/pg_upgrade/relfilenode.c
index 9a0a3ac18d9557cf696e452d4e61cab1b9c08485..6fb336cfc53d9ad65f2130e558ca4c8f2b59b406 100644 (file)
--- a/contrib/pg_upgrade/relfilenode.c
+++ b/contrib/pg_upgrade/relfilenode.c
@@ -37,6 +37,12 @@ transfer_all_new_dbs(DbInfoArr *old_db_arr,
prep_status("Restoring user relation files\n");
+ /*
+ * If the user removed the 'postgres' database from the old cluster,
+ * this will cause the database counts to not match and throw an error.
+ * We could allow this to work because the new database is empty (we
+ * checked), but we don't.
+ */
if (old_db_arr->ndbs != new_db_arr->ndbs)
pg_log(PG_FATAL, "old and new clusters have a different number of databases\n");
This is the main PostgreSQL git repository.
RSS Atom

AltStyle によって変換されたページ (->オリジナル) /