From: missive@frontiernet.net
To: pgsql-sql@postgresql.org
Subject: Re: How to see the definition of an existing table?
Date: Tue, 18 Sep 2001 00:37:46 +0000 (UTC)
Message-ID: <9o650p$2c1r$1@news.tht.net> (raw)
References: <5.1.0.14.2.20010914203358.00baabf8@postoffice.mail.cornell.edu>
On Mon, 17 Sep 2001 14:51:52 +0000 (UTC), ke wang <kw68@cornell.edu> wrote:
> Is there any command or query to see the definition of an existing table,
> like which is the primary key, which is not null etc.
>
In psql:
\d tablename
to see what the exact query is, start psql with the -E flag:
psql -E
\d tablename
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-sql@postgresql.org
Cc: missive@frontiernet.net
Subject: Re: How to see the definition of an existing table?
In-Reply-To: <9o650p$2c1r$1@news.tht.net>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox