Re: SHOW - Mailing list pgsql-general

From Joe Conway
Subject Re: SHOW
Date
Msg-id 025d01c1350d$e682e6f0$0705a8c0@jecw2k1
Whole thread Raw
In response to Re: SHOW  (bpalmer <bpalmer@crimelabs.net>)
List pgsql-general
> > > What is the equivalent to the mysql's:
> > > SHOW COLUMNS FROM [TABLENAME];
> >
> > in psql,  \d will show you all tables and \d TABLE will show you the
> > columns in the table.  If you need it as a sql command,  you can check
the
> > system tables.
>
> OK. That works for ./bin/psql, but NOT on the libpq's PQexec.
> What do I have to type here?
>
> Thanx again and lots of greetings from cool Spain
> Steve

Start up psql with the -E on the command line. Then do \d TABLE. This will
show you the actual SQL commands used by psql.

See the psql man page for more details.

HTH,

-- Joe


pgsql-general by date:

Previous
From: John Clark Naldoza y Lopez
Date:
Subject: Re: how do functional indices work?
Next
From: Giorgio Volpe
Date:
Subject: (no subject)