DrilldownLevel

Return to: Calculated Member Builder Function List

Drills down the members of a set to one level below the lowest level represented in the set, or to one level below an optionally specified level of a member represented in the set.

Syntax

DrilldownLevel(«Set»[, «Level»])

Remarks

The members that result from the drill down are hierarchized to occur under their parents. Order is preserved among the original members in «Set».

If «Level» is not specified, it is assumed to be the level of the lowest level member of «Set».

If «Level» is specified and there is no member of «Level» represented in «Set», «Set» is returned.

Alternate Syntax

DrilldownLevel(«Set», , «Index»)

Remarks

When drilling down in sets of tuples, the dimension to be drilled down can be specified by its zero-based numeric position in the tuples instead of by level. For example, in the set:

(Crossjoin(Crossjoin([Store Country].members,[Product Family].members),[Year].members)

a sample tuple is (Canada, Drink, 1998). The Store dimension is position 0, Product dimension is position 1, and Time dimension is position 2. The following expression drills down on the Product dimension:

DrilldownLevel(Crossjoin(Crossjoin([Store Country].members,[Product Family].members),[Year].members),,1)


Note The zero-based «Index» parameter is a Microsoft® SQL Server™ OLAP Services multidimensional expression (MDX) extension to OLE DB.


Example

DrilldownLevel({[Customers Location].USA, [Customers Location].CA, [Customers Location].WA, [Customers Location].Canada})

or, equivalently,

DrilldownLevel({[Customers Location].USA, [Customers Location].CA, [Customers Location].WA, [Customers Location].Canada}, [Customers Location].[State Province])

returns the set

{USA, CA, <all cities in CA>, WA,

<all cities in WA>, Canada}

whereas

DrilldownLevel({[Customers Location].USA, [Customers Location].CA, [Customers Location].WA, [Customers Location].Canada}, [Customers Location].[Country])

returns the set

{USA, CA, WA, Canada, BC}.

For more information, see the OLE DB documentation.

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