Search code examples
olapmondrianxmlaiccube

XML for Analysis (XML/A) format of member names?


I have two different XML/A providers, Mondrian and icCube. The tuples for a time dimension contain the unique name for the member, but the format of the member name is different:

Mondrian:

<UName>[Time].[2004].[QTR2].[Apr]</UName>
<Caption>Apr</Caption>
  • [Time] is the name of the hierarchy
  • [2004] is the name of the ancestor at the Year level
  • [QTR2] is the name of the ancestor at the Quarter level
  • [Apr] is the local name of the member at the Month level

icCube:

<UName>[Time].[Calendar].[Month].&amp;[Jun 2010]</UName>
<Caption>Jun 2010</Caption>
  • [Time] is the name of the dimension
  • [Calendar] is the the name of the hierarchy
  • [Month] is the name of the level
  • [Jun 2010] is the name of the month member.

(I don't know why the ampersands are there)

My question is, is there any recommended, preferably standard way to figure out how the member names are formatted?

The reason I want to know this is when I render the result in a Pivot table, the captions for the members will usually end up as labels on the headers of the pivot table. But since the captions may not be unique, it is desirable to also produce labels of the "ancestor" members, because together they do identify the member uniquely.

In my example, I could use the parts of the member unique name to do this, but in ic cube not,since the member u name is structured differently.

I have 2 questions:

1) How can I tell beforehand what format the XML/A provider will use to identify the members?

2) What would be the recommended way in ic cube to produce the labels for the ancestor members?

UPDATE:

Luc Boudreau informed me that the ampersand indicates "key notation" - it designates the member key rather than its name. Thanks Luc!


Solution

  • The meaning of unique names in MDX is a string that guarantees that it defines a unique MDX entity when parsed. There is no possible collision with another MDX entity. The way to write it depends on the XMLA provider. Even though it's 'unique' there are multiple ways creating it, each server chooses its way.

    Never mind, a query written in one server will work in another as both 'unique' names are correctly parsed.

    & amp; stands for &

    Our advise, the client code should not rely on the format of the unique names.

    That being said, if you need parent "names", you should retrieve them explicitly using the "Parent" function and/or as a calculated measure retrieving the name/caption property.

    Hope that helps.