Database Reference
In-Depth Information
US
US,
101,
2008
Country
Canada
2009
100
2008
101
Date
ProductId
FIGURE 9.4
Example of multidimensional clustering on a Sales table.
the table is part of exactly one block, depending on the values of dimension
columns. Additionally, each dimension column is associated with a dimension
index , which is a single-column B + -tree that has, at leaf nodes, pointers to
appropriate blocks in the MDC. Consider a Sales table defined as follows:
CREATE TABLE Sales (
date OrderDate,
int StoreId,
int ProductId,
int Country,
float Price )
Figure 9.4 illustrates an MDC table clustered along the dimensions Country ,
ProductId , and Date=yearOf(OrderDate) . Note that we can control the
granularity of the clustering by defining computed columns for the case of
OrderDate (which by itself might have resulted in a very sparse MDC). The
figure shows a simple logical cube with only two values for each dimension
column. Logical cells are represented by the subcubes in the figure (e.g., the
cell that corresponds to the combination (Canada, 100, 2008) ). A column
or row in the cube represents a slice for a particular dimension. For example,
all records containing the value Canada in the Country dimension are found
in the blocks contained in the slice defined by the Canada column in the cube.
Moreover, each block in this slice contains only records having Canada in the
Country field. The figure also shows dimension indexes created on each di-
mension column, which could be used to find the blocks that contain tuples
satisfying certain predicates over the dimension columns.
9.3.2 Query Processing
One of the goals of MDC is to facilitate ecient query processing for mul-
tidimensional range operations. Specifically, new processing techniques are
Search WWH ::




Custom Search