RE: what is the equivalent of oracle's DESCRIBE table? - Mailing list pgsql-general

From Andrew Perrin - Demography
Subject RE: what is the equivalent of oracle's DESCRIBE table?
Date
Msg-id Pine.WNT.4.05.10009151151200.281-100000@slovo
Whole thread Raw
In response to RE: what is the equivalent of oracle's DESCRIBE table?  ("chris markiewicz" <cmarkiew@commnav.com>)
List pgsql-general
use \d <tablename>


postgres@davis ~> psql demogdata
Welcome to the POSTGRESQL interactive sql monitor:
  Please read the file COPYRIGHT for copyright terms of POSTGRESQL
[PostgreSQL 6.5.0 on sparc-sun-solaris2.6, compiled by /usr/local/bin/gcc
]

   type \? for help on slash commands
   type \q to quit
   type \g or terminate with semicolon to execute query
 You are currently connected to the database: demogdata

demogdata=> \d event_detail
Table    = event_detail
+----------------------------------+----------------------------------+-------+
|              Field               |              Type                |
Length|
+----------------------------------+----------------------------------+-------+
| event_id                         | int4 not null default nextval('" |
4 |
| dt1eventid                       | int2                             |
2 |
| eventtypeid                      | int4                             |
4 |
| id                               | int4                             |
4 |
| date_effective                   | datetime                         |
8 |
| date_expires                     | datetime                         |
8 |
| expected                         | bool                             |
1 |
| title                            | varchar()                        |
150 |
| sourceid                         | int4                             |
4 |
| cost                             | float8                           |
8 |
| spec1                            | varchar()                        |
50 |
| spec2                            | varchar()                        |
50 |
| spec3                            | varchar()                        |
50 |
| spec4                            | varchar()                        |
50 |
| spec5                            | varchar()                        |
50 |
| spec6                            | varchar()                        |
50 |
| spec7                            | varchar()                        |
50 |
| spec8                            | varchar()                        |
50 |
| comments                         | text                             |
var |
| current_interests                | text                             |
var |
| updated                          | varchar()                        |
25 |
| override                         | varchar()                        |
25 |
| semester                         | varchar()                        |
15 |
| acadyear                         | varchar()                        |
12 |
| chair                            | int4                             |
4 |
| member1                          | int4                             |
4 |
| member2                          | int4                             |
4 |
| degree                           | varchar()                        |
5 |
+----------------------------------+----------------------------------+-------+
Indices:  date_effective_idx
          etid_detail_idx
          event_detail_event_id_key


---------------------------------------------------------------------
Andrew J. Perrin - aperrin@demog.berkeley.edu - NT/Unix Admin/Support
Department of Demography    -    University of California at Berkeley
2232 Piedmont Avenue #2120  -    Berkeley, California, 94720-2120 USA
http://demog.berkeley.edu/~aperrin --------------------------SEIU1199

On Fri, 15 Sep 2000, chris markiewicz wrote:

> \dt <table name> only seems to list Owner, Relation, and Type.
>
> i am looking for something that returns the same info that is found in a
> CREATE TABLE statement...column names, data types, etc.  i haven't seen
> anything like this in the documentation...
>
> thanks
> chris
>
> -----Original Message-----
> From: Len Morgan [mailto:len-morgan@crcom.net]
> Sent: Friday, September 15, 2000 9:48 AM
> To: cmarkiew@commnav.com
> Subject: Re: [GENERAL] what is the equivalent of oracle's DESCRIBE
> table?
>
>
> in psql: \dt <table name>
>
> -----Original Message-----
> From: chris markiewicz <cmarkiew@commnav.com>
> To: 'PostgreSQL General' <pgsql-general@postgresql.org>
> Date: Friday, September 15, 2000 8:51 AM
> Subject: [GENERAL] what is the equivalent of oracle's DESCRIBE table?
>
>
> >hello.
> >
> >what is the postgres equivalent of oracle's command-line DESCRIBE <table>
> >command?  does there exist a sql92 command for this?
> >
> >thank you
> >chris
> >
> >
>


pgsql-general by date:

Previous
From: Hernan
Date:
Subject: Re: are my questions being received?
Next
From: James Hall
Date:
Subject: RE: are my questions being received?