Re: Index Calculation Question

From: Steve Cosner <stevec_at_zimmer.CSUFresno.EDU>
Date: 1995/09/13
Message-ID: <DEv67u.G2o_at_CSUFresno.EDU>#1/1


In article <437d66$dpm_at_aplinfo.jhuapl.edu> Stan Novinsky <stan_novinsky_at_jhuapl.edu> writes:
>
>The Oracle7 Server Administration guide (pg 8-37 for OpenVMS)
>shows an example of calculating the avg. index size for an index of
>a table. The book states
>
> Entry Header 2 bytes
> ROWID 6 bytes
> F Total len bytes of all columns that store 128 bytes or
> less...
> V Total len bytes of all columns that store 128 or more ...
> D Combined data space of all index columns
>
>
>The book tends to lead one to believe that the size is calculated on
>all columns of the table. Is it actually only the columns that are
>used as indexes or is it actually all columns ? (I think it is only
>the columns usedas indexes). This would tend to make the tablespace
>size somewhat smaller for theindexes that the tablespace size for the
>actual tables that will be indexed...

Stan, on pg 8-36, step 3 specifically states "the average combined column lengths of the columns in the index."


>
>Also, the Entry Header in the book states 2 bytes, but the example
>below it uses 1 byte..
>Is it 1 byte or 2 bytes ????
>

I noted the same discrepancy between the text and the example also. I just used 2 bytes for the entry header to be sure. Remember, you are only _estimating_ here.

>Can someone please confirm these observations.
>
>Thanks
>stan_novinsky_at_jhuapl.edu
<snip>

By the way, the Step 5 equation looks pretty stupid to me... Note that "avg.entry size" is in both the numerator and denominator of the equation. Why did they do that???

Steve Cosner (stevec_at_csufresno.edu.us) Received on Wed Sep 13 1995 - 00:00:00 CEST

Original text of this message