Database Reference
In-Depth Information
Chapter 6. Adding Functionality to Your
Cube
The cube that we have created so far is very simple, it contains a couple of dimen-
sionsandtwomeasures;onemeasureshowingthesalesamountandtheothershow-
ing the count of the rows in the fact table.
In this chapter, we will start extending the cube. The following topics will be covered
in the chapter:
• Adding measures and measure groups
• Adding dimensions of different kinds
• Calculated measures and KPIs
• Calculated members
• Actions
Adding measures
Measures are crucial when building Analysis Services cubes. They are quantifiable
values usually tied to a column in a fact table. The most common method of defining
measures is to use aggregate functions such as sum, min, max, distinct count, and
count on a numeric column. A measure can also be defined using an expression that
calculates values using an MDX statement—this is called calculated measures .
The fact table that has been used throughout this topic called FactInternetSales
contains several columns that describe different facts about an individual transaction.
So far in this topic you have worked with the Sales Amount measure that describes
the sales amount for an individual order row. The FactInternetSales table also
contains information about the order quantity, the price, the discount amount, and oth-
er measures that are included in the transaction. These columns are interesting when
analyzing the sales information; all we need to do is to add them to our measure
group. In order to add them, perform the following steps:
1. In the Solution
Explorer , double-click on the Adventure
Works
DW2012.cube file.
Search WWH ::




Custom Search