Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.server -> Re: 10g CBO and how to determine cardinality on INDEX_FFS?
So the cost makes sense..
(LEAF_BLKS/MBRC) * (MREADTIM/SREADTIM)
+
#CPUCycles / (cpuspeed * sreadtim_in_microseconds)
IOCOST = (39550/125) * (26.806/4.245) = 1997.97842
+
CPUCOST= 281652952 / (198 * (4.245*1000)) = 335.097681
= 2333.0761 which is very close to 2335 as calculated by the
optimizer.
I'm still having some difficulties calculating the cardinality though.
This is probably since I have a histogram on the product_id column.
I've checkout
chapter 7 on histograms, but can't make the numbers add up.
This is what's currently in my user_tab_histograms view. There are only 2 values for product_id in that table.
ENDPOINT_NUMBER|ENDPOINT_VALUE
---------------|--------------
1354519| 430657811 1943369| 438075481
if you have a moment, any additional hints would be greatly
appreciated.
I think I'm still not sure of what are the standard rules for
calculating the
cardinality on columns with frequency histograms.
thanks again
--peter
Received on Sat Nov 19 2005 - 00:52:46 CST
![]() |
![]() |