Re: [GENERAL] Comments on tables, functions, etc.

From: "Ross J(dot) Reedstrom" <reedstrm(at)rice(dot)edu>
To: Michael Davis <michael(dot)davis(at)prevuenet(dot)com>
Cc: "PGSQL-General (E-mail)" <pgsql-general(at)postgresql(dot)org>
Subject: Re: [GENERAL] Comments on tables, functions, etc.
Date: 1999-02-25 18:48:46
Message-ID: 36D59B0E.6AA8E809@rice.edu
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Michael -
I was just wondering this myself! I even dug into the source code, to
see if I could find how the comments get in there. Couldn't find any
existing SQL or psql command syntax, so I'm doing this:

template1=> \d pg_description

Table = pg_description
+----------------------------------+----------------------------------+-------+
| Field | Type |
Length|
+----------------------------------+----------------------------------+-------+
| objoid | oid
| 4 |
| description | text
| var |
+----------------------------------+----------------------------------+-------+
Index: pg_description_objoid_index
template1=> select oid from pg_class where relname = 'fred';
oid
-----
66464
(1 row)

template1=> insert into pg_description values (66464,'This is the table
fred') ;

INSERT 66473 1
template1=> \dd fred
description
----------------------
This is the table fred
(1 row)

template1=>

Michael Davis wrote:
>
> How can I add a comment to a table, function, etc. that will should up in a
> /dd comment in psql?

--
Ross J. Reedstrom, Ph.D., <reedstrm(at)rice(dot)edu>
NSBRI Research Scientist/Programmer
Computer and Information Technology Institute
Rice University, 6100 S. Main St., Houston, TX 77005

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Ephren Taylor 1999-02-25 22:11:33 PgAdmin Location
Previous Message Michael Davis 1999-02-25 18:35:30 Comments on tables, functions, etc.