Re: Re: Newbie question: How to check how many tables avaliable at that database?

Поиск
Список
Период
Сортировка
От will trillich
Тема Re: Re: Newbie question: How to check how many tables avaliable at that database?
Дата
Msg-id 20010621133703.B7582@serensoft.com
обсуждение исходный текст
Ответ на Re: Newbie question: How to check how many tables avaliable at that database?  (Nils Zonneveld <nils@mbit.nl>)
Список pgsql-general
On Wed, Jun 13, 2001 at 07:25:46PM +0200, Nils Zonneveld wrote:
>
>
> Carfield Yim wrote:
> >
> > I am a  new user of PostgreSQL dbms, how can I check how many tables
> > avaliable at that database?
>
> To get a list of tables through SQL:
>
> SELECT tablename FROM pg_tables WHERE tablename NOT LIKE 'pg_%' ORDER BY tablename;
>
> To get the number of tables through SQL:
>
> SELECT count(*) FROM pg_tables WHERE tablename NOT LIKE 'pg_%';

to learn more of these tricks, start 'psql' with '-E' as in

    psql -E mydatabasenamehere

then when you give any '\d' command you'll see the sql behind
the scenes that does the work.

also try '\?' for more info on using psql.

--
I figure: if a man's gonna gamble, may as well do it
without plowing.   -- Bama Dillert, "Some Came Running"

will@serensoft.com
http://sourceforge.net/projects/newbiedoc -- we need your brain!
http://www.dontUthink.com/ -- your brain needs us!

В списке pgsql-general по дате отправления:

Предыдущее
От: "Jim Buttafuoco"
Дата:
Сообщение: WAL failure?
Следующее
От: will trillich
Дата:
Сообщение: Re: Moving rows to another database