ParentName (Property)

Applies To:

OLAPLevelorHierarchy collection, (CubeQuery) OLAPLevelorHierarchyNew collection, Measures collection

Description:

Returns the parent name value of the OLAP level or hierarchy.

Action:

Read only, String

Example 1:

This example shows how to display the parent name of an OLAP level or hierarchy in an Alert box:

Alert(ActiveDocument.Sections["OLAPQuery"].Catalog.Dimensions["Customers"]["Country"].ParentName)

Example 2:

This example shows how to return the parent name and unique name for the product dimension in a Console window:

var products = Sections["Query"].Catalog.Dimensions["Product"]["100"];
for (var i = 1; i <= products.Count; i++) {
    Console.Writeln(products[i].Name);
    Console.Writeln(products.Item(i).UniqueName);
    Console.Writeln(products.Item(i).ParentName);
}