Re: problems with pg_restore - Mailing list pgsql-admin

From Kuhn, Dylan K (4520500D)
Subject Re: problems with pg_restore
Date
Msg-id 78ED1F30F0D85B4698FBD6CF2A5AC8F5A576FA@NAWECHLKEX01VA.nadsuswe.nads.navy.mil
Whole thread Raw
In response to problems with pg_restore  ("Kuhn, Dylan K (4520500D)" <Dylan.Kuhn@navy.mil>)
List pgsql-admin
> Hm.  Evidently not :-(.  The COMMENT ON DATABASE facility is
> a bit bogus
> anyway (since there's no way to make the comments visible across
> databases).  You might be best advised not to use it.

I agree.  I plan to delete it and try again, and avoid using database comments in the future.  This seems to work:

DELETE FROM ONLY pg_description
 WHERE pg_description.objoid=
     (SELECT pg_database.oid FROM pg_database WHERE pg_database.datname=current_database())
   AND pg_description.classoid=
     (SELECT pg_class.relfilenode FROM pg_class WHERE pg_class.relname='pg_database');

> (though I'm
> not quite sure how to phrase the warning ...).  Any thoughts?

I would have been happy enough with the existing message as a warning - probably anyone who tries to use database
commentshas noticed the limitations. 

-dylan-

pgsql-admin by date:

Previous
From: Tom Lane
Date:
Subject: Re: problems with pg_restore
Next
From: Tom Lane
Date:
Subject: Re: problems with pg_restore