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

Home -> Community -> Mailing Lists -> Oracle-L -> Re: Estimate versus Compute

Re: Estimate versus Compute

From: Wolfgang Breitling <breitliw_at_centrexcc.com>
Date: Mon, 25 Jul 2005 13:03:56 -0600
Message-ID: <42E5379C.6060208@centrexcc.com>


Are you using
a) analyze or dbms_stats
b) block sampling or row sampling

The argument for estimate > 1% causing all blocks to be read anyways goes something like this:
If you are using row sampling with 25% (for the sake of argument) and you have more than 4 rows per block on average then a random sampling of 25% (1 out of every 4 rows) is likely to give you a row from every block. That argument of course doesn't hold if you are using block sampling. Then a 25% sample will read 1/4 of all blocks.

Allen, Brandon wrote:
> Mike, I don't believe that is true. I recently reduced from compute to estimate=25% and this reduced the runtime for update stats from 38 hours to 14 hours. I don't think it would make such a difference if it still had to visit every block. I think you can specify whether your samples are based on rows or blocks and Oracle will automatically compute if you specify estimate >= 50%.
>
> Regards,
> Brandon
>
>

-- 
Regards

Wolfgang Breitling
Centrex Consulting Corporation
www.centrexcc.com
--
http://www.freelists.org/webpage/oracle-l
Received on Mon Jul 25 2005 - 14:06:18 CDT

Original text of this message

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