Patent ID: 7765211

Claim:
A computer program product stored on a computer readable storage medium for reducing the number of blocks searched when inserting a record into a multidimensional database and clustering data, the computer program product configured to cause: receiving a record to be inserted into the multidimensional database, the record corresponding to a cell in the multidimensional database, wherein the cell is a unique combination of dimension values; searching a composite dimension index for one or more blocks that correspond to the cell of the record to be inserted using a dimension key value, wherein the composite dimension index associates the cells in the multidimensional database with blocks on a storage device; in response to finding a block having a key value matching the unique dimension values of the record to be inserted, determining whether a block identifier (BID) for the block indicates that the block is full; in response to the BID indicating that the block is not full, searching the block for space to store the record to be inserted; in response to the BID indicating that the block is full, adding the block to a list in memory of blocks with BIDs indicating that the blocks are full and determining whether a second block having a key value matching the unique dimension values of the record to be inserted has a BID indicating that the second block is full; and in response to finding space in the block to store the record to be inserted, inserting the record such that records corresponding to like cells in the multidimensional database are clustered.