Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.misc -> Definition of "Selectivity"
I'm a bit confused over Oracle's definition of index selectivity....
The documentation says that you divide the number of rows by the cardinality of the index and the results should be expressed as a percentage.
They define selectivity as "the percentage of rows in a table having the same value for the indexed column"....
By using the formula above on a column with 10 rows and cardinality of 2:
10 / 2 = 5 <--- but this isn't a percentage!
To me, the formula based on the definition should be:
rows / cardinality / rows
-or-
the inverse of the cardinality....
In the example, you'd get 20% which is the correct answer assuming uniform distribution....
Where am I going wrong?
Thanks. Received on Fri Jun 04 1999 - 11:34:00 CDT
![]() |
![]() |