Re: Number of rows of a table

Поиск
Список
Период
Сортировка
От Michael Glaesemann
Тема Re: Number of rows of a table
Дата
Msg-id ED3BE54F-E84A-49A0-B984-BD7233200174@myrealbox.com
обсуждение исходный текст
Ответ на Number of rows of a table  (vittorio <vdemart1@tin.it>)
Ответы Re: Number of rows of a table  ("Jim C. Nasby" <jnasby@pervasive.com>)
Список pgsql-general
On Oct 19, 2005, at 2:29 , vittorio wrote:

> Using psql how can I ask postgresql to show the actual number of
> rows of a
> table?

For table foo,

select count(*) from foo;

An up-to-date count of the number of actual rows is not stored some
place in the database. If an estimate is adequate for your purposes,
you might want to look at some of the system tables which track row
counts for query planning strategy. I don't recall offhand which
column of which system table you'd want to look at, unfortunately.

Michael Glaesemann
grzm myrealbox com




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

Предыдущее
От: "Tadimeti, Kesav"
Дата:
Сообщение: postgresql8.0.3/FreeBSD5.4/MIT or HEIMDAL KRB5
Следующее
От: Michael Glaesemann
Дата:
Сообщение: Re: Wrong charset?