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: NUM_ROWS vs COUNT(*) anomaly

Re: NUM_ROWS vs COUNT(*) anomaly

From: Igor V. Podolsky <igoryok_at_soft-review.kiev.ua>
Date: Thu, 13 Jan 2000 12:57:08 +0200
Message-ID: <AAvzQVuy90I@soft-review.kiev.ua>


Hi !

> If I do
>
> SELECT table_name, num_rows
> FROM user_tables
> WHERE table_name='table_A';
>
> I get a value for num_rows of 5424908.
>
> If, however I just do
>
> SELECT count(*)
> FROM table_A;
>
> I get a value of 5424804 (incidentally, the correct value).
>
> OK, so I know that num_rows is from the data dictionary and the count is
> directly on the table, but why are the values different? Any ideas??

May be You'd analyse table (at least partially) first to get a real num_rows value from data dictionary ?

--
Is There A God Or Any Kind Of Justice Under The Sky... (Queen'91)

Igor V. Podolsky (igoryok_at_soft-review.kiev.ua) Received on Thu Jan 13 2000 - 04:57:08 CST

Original text of this message

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