Home » RDBMS Server » Server Administration » How to calculate the number of hash keys (Oracle 11gr2 ,)
How to calculate the number of hash keys [message #501831] Thu, 31 March 2011 20:30 Go to next message
kytemanaic
Messages: 55
Registered: February 2009
Member
Hi,

I was reading the documentation for oracle 11gr2, with reference to http://download.oracle.com/docs/cd/E11882_01/server.112/e17120/hash003.htm#sthref2548

Quote:


The following examples show how to correctly choose the cluster key and set the HASH IS, SIZE, and HASHKEYS parameters. For all examples, assume that the data block size is 2K and that on average, 1950 bytes of each block is available data space (block size minus overhead).
......


Note that 34 hash keys are assigned for each data block


The problem is I don't understand how they arrive at 34 hash keys

because another portion of the document states

Quote:


This space determines the maximum number of cluster or hash values stored in a data block. If SIZE is not a divisor of the data block size, then Oracle Database uses the next largest divisor.


if that is the case,

then number of hash keys should be 1900/55 = 34.55

which should have rounded up to 35.

Could anyone kindly clarifies? thanks a lot!
Re: How to calculate the number of hash keys [message #501840 is a reply to message #501831] Thu, 31 March 2011 23:34 Go to previous message
Michel Cadot
Messages: 68718
Registered: March 2007
Location: Saint-Maur, France, https...
Senior Member
Account Moderator
The largest divisor is the greatest integer below, so fro 34.55, it is 34.
You cannot store 35 keys when the maximum of free space is 34.55, you can store at most 34.

Regards
Michel
Previous Topic: new feature of 11g
Next Topic: Move partitioned table between table spaces of different block size.
Goto Forum:
  


Current Time: Fri Nov 29 06:56:39 CST 2024