By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
464,788 Members | 1,408 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 464,788 IT Pros & Developers. It's quick & easy.

How to show database table/view/... declaration?

P: n/a
Hi,

I've been working a lot with MySQL for quite a while and now I'm trying to
get into PostgreSQL.

One problem that I still have and could not find an answer is how to get the
declaration of a table, view and so on. In MySQL I do it with 'show create
table', 'show create view' and so on, or by 'explain [tablename]'. Is there
an equivalent in PostgreSQL? Maybe in information_schema? How do I access
information_schema in PostgreSQL?

Thanks for any help ;-).

Markus
Sep 5 '05 #1
Share this Question
Share on Google+
1 Reply

P: n/a
PK
Markus Popp napisał(a):
One problem that I still have and could not find an answer is how to get the
declaration of a table, view and so on. In MySQL I do it with 'show create
table', 'show create view' and so on, or by 'explain [tablename]'. Is there
an equivalent in PostgreSQL? Maybe in information_schema? How do I access
information_schema in PostgreSQL?

I don't know if there is an equivalent to such commands, but you can use
pg_dump program to get the schema.
PK
Sep 8 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.