Attribute Member Keys - Pt II: Composite Keys - Page 4
September 19, 2008
Procedure: Examine Key Attribute Properties and Characteristics in Analysis Services 2005 (Composite Key)
In the practice procedures that follow, we will select and examine a representative key attribute within the sample cube, focusing upon the properties that define and support such an attribute. We will perform our practice sessions within the SQL Server Business Intelligence Development Studio, from which we will perform our examination of attribute properties within our Analysis Services database, ANSYS065_Basic AS DB.
In Dimensional Model Components: Dimensions Part I and II, and Dimensional Attributes: Introduction and Overview Parts I through V, respectively, we overviewed the properties underpinning Database and Cube dimensions, and then examined the properties supporting dimension attributes. Moreover, in Part I of this article, we focused upon those properties for a simple attribute key. Just as we did in those articles, we will examine the detailed settings for a representative attribute member key here, concentrating on those settings within the context of a composite key. To access these settings for the attribute member key within a representative dimension, we will need to open that dimension within the Dimension Designer first.
1. Within the Solution Explorer, right-click the Time dimension (expand the Dimensions folder as necessary).
2. Click Open on the context menu that appears, as shown in Illustration 5.
The tabs of the Dimension Designer open.
3. Click the Dimension Structure tab, if we have not already arrived there by default.
4. Examine the member attributes that appear within the Attributes pane of the Dimension Structure tab.
The attributes belonging to the Time dimension appear as depicted in Illustration 6.
We note that eight attributes appear within the Attributes pane. Let's get some exposure to the properties associated with attribute keys (in particular, a composite key) by examining a representative member among the attributes we see here.
Review Key Attribute Properties
In Dimensional Attributes: Introduction and Overview Part V, and as a part of our more detailed exploration in Attribute Member Keys Pt I: Introduction and Simple Keys, we discovered that, within the Source properties of every attribute lays the KeyColumns property. Lets examine the property and the underlying KeyColumns collection for the Calendar Quarter attribute key, which represents a composite key within the sample Analysis Services database, by taking the following steps.
1. Within the Attributes pane of the Dimension Structure tab, right-click the Calendar Quarter Key attribute.
2. Click Properties on the context menu that appears, as shown in Illustration 7.
The Properties pane appears for the Calendar Quarter attribute key. (The Properties pane likely appeared when we selected the Calendar Quarter attribute key within the Attributes pane, by default, below the Solution Explorer. The design environment can, of course, be customized in many ways to accommodate your local environment and development needs.)
3. Expand the Source group, at the bottom of the Properties pane, by clicking the + sign that appears to the immediate left of its label, if necessary, as depicted in Illustration 8.
The expanded Source properties group of the Properties pane for the Calendar Quarter attribute key appears as shown in Illustration 9.
Let's take a look at each of the individual properties (and subproperties), as relevant to a composite key, discussing the purpose of the property, and examining possible settings with which we can come into contact. (As we have noted, we examine these settings for a simple key in Part I.) In most attributes, we find that only the KeyColumns property is relevant, from the perspective of simple or composite keys, although NameColumn and ValueColumn can certainly offer opportunities for employment, as we see in other articles of this series. We will skip the CustomRollupColumn and CustomRollupPropertiesColumn properties for this reason both are set to (none) in the case of our example, the Calendar Quarter attribute key.