I am trying to write an mdx ranking query.\n\nSome background: I am collecting performance measure data on stores.\nStores are heirarchized by Region -> Area -> Unit. Performance\nmeasures are also heirarchized, and are derived by applying a scoring\nformula to a question. My measures dimension contains a calculated\nAverage Score.\n\nI have a performance measure hierachy, EG:\n\n-> Score Group\n-> Loyalty Score\n-> Cleanliness Score\n- Q1\n- Q2\n-> Quality Score\n- Q1\n- Q2\n-> Service Score\n- Q1\n\nAnd a unit hierarchy, EG:\n\n-> Region 1\n-> Area 1\n- unit1\n- unit2\n-> Area 2\n- unit1\n- unit2\n-> Region 2\n-> Area 1\n- unit1\n- unit2\n-> Area 2\n- unit1\n- unit2\n-> Area 3\n- unit1\n- unit2\n\nWhat i am trying to do is create a mdx query that will show the units\non columns (crossjoined with the measures average score and rank) and\nthe heirchized performance measures on rows. The difficulty i am\nhaving is creating the calculated rank measure. The rank must be\ncalculated per performance measure across the set of displayed unit.\nThe result shoud look somthing like this (if i chose the members of\nregion 2 on my columns):\n\nArea1 Area2 Area3\nAverage Score|Rank Average Score|Rank Average Score|Rank\n\nLoyalty 54 2 49 3 56 1\nCleanliness 50 3 55 1 51 2\nQ1 44 1 41 3 43 2\nQ2 ...\nQuality ...\nQ1\nQ2\nService\nQ1\nQ2\n\nThanks.