Hi List;

I want to pull the list of column names from the system catalogs for a specified table. I only want column names, I want to exclude any index names, or other non-column name rows. I got this far (see below) however this query produces additional rows with attname's like tableoid, cmax, xmax ctid, etc.

select attname from pg_attribute where attrelid = (select oid from pg_class where relname = 'my_tablename');

Any thoughts ?

Thanks in advance...



--
Sent via pgsql-admin mailing list (pgsql-admin@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-admin

Reply via email to