Re: Is there no "DESCRIBE <TABLE>;" on PGSQL? help!!!

From: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
To: Ron de Jong <Ron(dot)Antispam(at)news(dot)tht(dot)net>
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: Is there no "DESCRIBE <TABLE>;" on PGSQL? help!!!
Date: 2001-10-19 14:57:44
Message-ID: 200110191457.f9JEvi828304@candle.pha.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers


psql \d command.

> Any idea to get a human readable list with column descriptions like
> type,size,key,default,null.
> It would be nice if it would look simular to the mysql variant:
>
> mysql> describe employee;
> +-----------+----------+------+-----+---------+----------------+
> | Field | Type | Null | Key | Default | Extra |
> +-----------+----------+------+-----+---------+----------------+
> | Id | int(11) | | PRI | NULL | auto_increment |
> | FirstName | char(30) | | MUL | | |
> | LastName | char(30) | | | | |
> | Infix | char(10) | YES | | NULL | |
> | Address1 | char(30) | YES | | NULL | |
> | PostCode | char(10) | YES | | NULL | |
> | Town | int(11) | YES | | NULL | |
> +-----------+----------+------+-----+---------+----------------+
>
> Cheers, Ron.
>
>

--
Bruce Momjian | http://candle.pha.pa.us
pgman(at)candle(dot)pha(dot)pa(dot)us | (610) 853-3000
+ If your life is a hard drive, | 830 Blythe Avenue
+ Christ can be your backup. | Drexel Hill, Pennsylvania 19026

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Bruce Momjian 2001-10-19 15:04:56 Re: compiling on Solaris 8 x86
Previous Message Gunnar Rønning 2001-10-19 14:54:18 Re: schema support, was Package support for Postgres