| From: | Oliver Kohll <oliver(at)gtwebmarque(dot)com> |
|---|---|
| To: | pgsql-general(at)postgresql(dot)org |
| Subject: | Retrieving a column comment |
| Date: | 2003-10-26 22:02:22 |
| Message-ID: | 200310262202.22396.oliver@gtwebmarque.com |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-general |
Hi,
I can't seem to retrieve a comment on a table column. The following copy from
psql should I think return a comment:
====================
mydatabase=> COMMENT ON COLUMN car.manufacturer IS 'manufacturer name';
COMMENT
mydatabase=> SELECT relnamespace FROM pg_class WHERE relname='car';
relnamespace
--------------
2200
(1 row)
mydatabase=> SELECT col_description(2200,1);
col_description
-----------------
(1 row)
====================
i.e. it just returns a blank row.
The col_description is described at
http://www.postgresql.org/docs/7.3/static/functions-misc.html
The field number supplied above '1' is right if the first col in a table is
'0', in fact no number I've tried returns anything.
I can't seem to find any examples at all on the web about retrieving column
COMMENTs. Has anyone done this? Postgres version is 7.3
Regards,
Oliver Kohll
GT webMarque
--
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Yonatan Goraly | 2003-10-26 22:08:31 | Slow query |
| Previous Message | John DeSoi | 2003-10-26 21:41:16 | Re: shared memory on OS X - 7.4beta4 |