Level Interface

Levels describe the hierarchy within a dimension from the highest (most aggregated) level to the lowest (most detailed) level of data. The following table shows an example of level positions of a time dimension in which the most detailed (day) values are included in the next level (week), which are in turn included in the next level (quarter), and so on.

Level Position
All 1
Year 2
Quarter 3
Week 4
Day 5

The number of members in any level must always be greater than, or equal to, the number of members in the parent level. For example, a level for Year may have four members 1994 through 1997. A subordinate level for Quarter would have four members for each year, Week would have 52 members for each year, and so forth. In Decision Support Objects (DSO), the objects that implement the Level interface have a ClassType property value of clsAggregationLevel, clsCubeLevel, clsDatabaseLevel, or clsPartitionLevel. Additionally, the SubClassType property for level objects may have a value of sbclsVirtual (as well as sbclsRegular) indicating that this is a virtual level. Virtual levels are used in the same manner as regular levels. The advantage to using a virtual level is that it does not add additional storage overhead to the cube because the members of a virtual level are calculated on demand. However, because members are dynamically calculated, virtual levels can be slower in responding to queries. By defining a level as virtual, the parent dimension object is also considered virtual. For more information, see Dimension Interface, MemberKeyColumn, and SubClassTypes in Enumerations.

The Level interface provides a number of properties to manipulate these objects. For an overview of levels and other objects, see About Decision Support Objects.

Each of these objects implements the Level interface, but not necessarily all of the Level properties. Other differences in the implementation of the Level interface exist among the objects. Some Level properties may be restricted to read-only access by some objects. For example, a clsDatabaseLevel object allows read and write access to its LevelType property whereas access to this property for a clsPartitionLevel object is read-only. For more information about the Level interface properties and applicability to the associated objects, see Collections and Properties.

There are no methods associated with the Level interface.

Applies To
clsAggregationLevel clsDatabaseLevel
clsCubeLevel clsPartitionLevel

(c) 1988-1998 Microsoft Corporation. All Rights Reserved.