Looking for a "show create table " equivalent

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

I've been trying to find out how to find out which sql was run to create
a certain table. As I need this in a program which may access the
database remotely, using pg_dump --schema-only or psql is not an option
(the system my program runs on may not even have those tools installed).
Looking at the source of pgadmin3 it seems as if the program collects
all info about the given table (columns, indeces etc) and creates the
needed SQL by itself, is there no easier way?

E.g. MySQL offers a simple "show create table <name>". I am using
Postgresql 9.0.4 on Gentoo.

Thanks for your help (if there is any documentation which I haven't
found yet, just point me to it).

Sincerely
Bettina


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

Предыдущее
От: Gavin Flower
Дата:
Сообщение: Re: using explain output within pgsql
Следующее
От: Jose Ig Mendez
Дата:
Сообщение: newbie question * compare integer in a "where IN" statement