Performances

Поиск
Список
Период
Сортировка
Искать

Performances

От:
Cedric BUSCHINI <cbuschini@carax.com>
Дата:
Hello everyone,

A quick question:
- how long does it take you to perform that query :
"SELECT COUNT(*) FROM A_TABLE;"

There are like 56113000 rows in the table.

Thanks

Cedric

Re: Performances

От:
Bricklen Anderson <banderson@presinet.com>
Дата:
Cedric BUSCHINI wrote:
> Hello everyone,
> 
> A quick question:
> - how long does it take you to perform that query :
> "SELECT COUNT(*) FROM A_TABLE;"
> 

Not long  :)

dev5=# SELECT COUNT(*) FROM A_TABLE;
ERROR:  relation "a_table" does not exist

Re: Performances

От:
Alvaro Herrera <alvherre@commandprompt.com>
Дата:
Cedric BUSCHINI wrote:
> Hello everyone,
> 
> A quick question:
> - how long does it take you to perform that query :
> "SELECT COUNT(*) FROM A_TABLE;"

Longer than I want to wait in any case.  In most cases you can rewrite
that query to something else; what that something looks like, depends on 
how exact you want the result to be.  So the question to you is, what do
you want that number for?

-- 
Alvaro Herrera                                http://www.CommandPrompt.com/
PostgreSQL Replication, Consulting, Custom Development, 24x7 support
FAQ