Re: DELETE FROM pg_description WHERE ... - Mailing list pgsql-admin

From Simon Riggs
Subject Re: DELETE FROM pg_description WHERE ...
Date
Msg-id BANLkTikCbyLiad2C9ELzMMxecJ1-bD69fg@mail.gmail.com
Whole thread Raw
In response to DELETE FROM pg_description WHERE ...  (Erwin Brandstetter <brsaweda@gmail.com>)
Responses Re: DELETE FROM pg_description WHERE ...
List pgsql-admin
On Fri, Apr 22, 2011 at 5:26 PM, Erwin Brandstetter <brsaweda@gmail.com> wrote:
> Hi!
>
> It is generally not advisable to write to system catalogs directly ...
>
> However, I have a database with dozens of schemas and hundreds of
> tables. There is a bunch of useless comments on columns I want to get
> rid of, scattered all across the db. The fastest & easiest way would
> be:
>
> DELETE FROM pg_description WHERE description = 'My very special
> totally useless comment.';

Why would you *not* use the COMMENT command for that?

What is slower or harder about using it?

--
 Simon Riggs                   http://www.2ndQuadrant.com/
 PostgreSQL Development, 24x7 Support, Training & Services

pgsql-admin by date:

Previous
From: Craig James
Date:
Subject: Re: select for update
Next
From: Tom Lane
Date:
Subject: Re: DELETE FROM pg_description WHERE ...