Обсуждение: list tables Examples

Поиск
Список
Период
Сортировка

list tables Examples

От
"Luiz Rafael Culik Guimaraes"
Дата:
Dear Friend

I searched all postgresql page and didn´t find.
How to get all tables associated with an Database with C API.
as Mysql api mysql_list_tables

[]´s

Luiz Rafael Culik
http://sites.uol.com.br/culikr



Re: list tables Examples

От
Alvaro Herrera
Дата:
Luiz Rafael Culik Guimaraes dijo:

> How to get all tables associated with an Database with C API.

Use a standard query against pg_class system table, or (probably better)
pg_tables system view.

--
Alvaro Herrera (<alvherre[a]atentus.com>)
"Postgres is bloatware by design: it was built to house
 PhD theses." (Joey Hellerstein, SIGMOD annual conference 2002)


Re: list tables Examples

От
am@fx.ro
Дата:
On Tue, Aug 13, 2002 at 01:25:44PM -0300, Luiz Rafael Culik Guimaraes wrote:
> Dear Friend
>
> I searched all postgresql page and didn´t find.
> How to get all tables associated with an Database with C API.
> as Mysql api mysql_list_tables

You'll have to fetch the results of a query like:

select tablename from pg_tables

or

select tablename from pg_tables where not tableowner='postgres'


Adrian Maier
(am@fx.ro)