Re: Which table(s) in the catalog define the tables and views?

From: Michael Glaesemann <grzm(at)myrealbox(dot)com>
To: Chris Velevitch <chris(dot)velevitch(at)gmail(dot)com>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: Which table(s) in the catalog define the tables and views?
Date: 2006-01-26 06:26:17
Message-ID: CA166D36-BDFF-4FDF-B849-E7CC1393EDB0@myrealbox.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general


On Jan 26, 2006, at 15:17 , Chris Velevitch wrote:

> I'm want to write a query to list definitions of all the fields in my
> tables and which table it belongs to. And similarly for views and
> tables.
>
> This is so I can check for table and column name consistency, extra
> tables and column type consistency.

It's not a query, but will pg_dump -s do what you want?[1] Else you
can take a look at the INFORMATION_SCHEMA[2] or the system catalogs[3].

[1](http://www.postgresql.org/docs/current/interactive/app-pgdump.html)
[2](http://www.postgresql.org/docs/current/interactive/information-
schema.html)
[3](http://www.postgresql.org/docs/current/interactive/catalogs.html)

Michael Glaesemann
grzm myrealbox com

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Agnes Bocchino 2006-01-26 06:49:00 Re: Initdb panic: invalid record offset at 0/0 creating
Previous Message Chris Velevitch 2006-01-26 06:17:51 Which table(s) in the catalog define the tables and views?