Link to home
Start Free TrialLog in
Avatar of Luigi2009
Luigi2009Flag for Czechia

asked on

How to show primary key of Parent-Child hierarchy

I have dimesion with ragged Parent-Child hierarchy. For instance organizational structure of a company. Commonly the hierarchy shows names of hierarchy items but now I need to create MDX query where result on axis 1 will be ID (primary key of dimesion) of item and name of item, but main is to show id.

SELECT {} ON 0,
{[Product].[MetaGroupHierarchy].children} ON 1
FROM MyOLAPCube

With mentioned MDX query the result is :

name1
name2
name3
...

And I would like to have:
ID1, name1
ID2, name2
ID3, name3

or

ID1
ID2
ID3


I do not know how to construct MDX query in this case.  Because main dimesion key has to have NameColumn property set to filed with name of item.

ASKER CERTIFIED SOLUTION
Avatar of rashmi_vaghela
rashmi_vaghela
Flag of India image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of Luigi2009

ASKER

No concrete sulution only link to MDX web's