Re: [INTERFACES] Perl Interface

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: [INTERFACES] Perl Interface
Дата
Msg-id 23325.935418642@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Perl Interface  (Robert Hiltibidal <rob@y2k.state.il.us>)
Список pgsql-interfaces
Robert Hiltibidal <rob@y2k.state.il.us> writes:
> How can I get perl to pull the field names from a table? 

This isn't specifically a perl question, it's just a matter of knowing
which system tables to look in.  Try

select attname from pg_attribute, pg_class where
attrelid = pg_class.oid and attnum > 0 and relname = 'XXX';

BTW, it's easy to explore the system tables in psql.  Use \dS to get
a list of system tables, and then \d and normal SQL commands to look
at any of them that sound interesting.  Or look at the definitions in
pgsql/src/include/catalog/.
        regards, tom lane


В списке pgsql-interfaces по дате отправления:

Предыдущее
От: Robert Hiltibidal
Дата:
Сообщение: Perl Interface
Следующее
От: "Rontxi A."
Дата:
Сообщение: subscribe