Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Re: count of rows without select count(*) command...

Re: count of rows without select count(*) command...

From: Sybrand Bakker <postbus_at_sybrandb.demon.nl>
Date: Sat, 14 Nov 1998 17:23:53 +0100
Message-ID: <364DAE99.FB0918FA@sybrandb.demon.nl>


This is possible by retrieving the num_rows column of user_tables. This will work however only after analyze table <xyz> compute. If you don't analyze your tables, you will not be able to use this trick, which is dangerous anyway, as this number is static. AFAIK the number of rows is also maintained in the table header block and there is a special operation for retrieving the count. You shouldn't need to execute a full table scan.

Hth,

Sybrand Bakker, Oracle DBA

BluesMan wrote:

> Hi all,
>
> I have a table with near 150 M rows (12Go)...
>
> ...How could I know the number of rows without the ' select count(*) from
> table_name ' command ?
> for instance in the system tables...
>
> no statistics are launched...
>
> Thanks
>
> gotblues_at_mygale.org


Received on Sat Nov 14 1998 - 10:23:53 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US