Re: About table schema - Mailing list pgsql-general

From Peter Eisentraut
Subject Re: About table schema
Date
Msg-id 200405261928.37876.peter_e@gmx.net
Whole thread Raw
In response to About table schema  (Wei Shi <weishisky@yahoo.com>)
List pgsql-general
Wei Shi wrote:
> Hi, does anyone know how to get the schema information
> of a table.  More specifically, I would like to know
>
> 1. which field(s) are primary keys?
> 2. the data type of each field of a table?
> 3. If a field is a foreign key, what field/table it
> is referring to.

Use the information schema views.


pgsql-general by date:

Previous
From: Bruce Momjian
Date:
Subject: Re: [HACKERS] COPY formatting
Next
From: Frank Finner
Date:
Subject: Re: performance very slow