Predefined Sorting in MDX
I am dealing with Occupancy Rate in Hotel Industry.
I would like to display [Measures].[Taux Occupation] ordered by categorie DESC and according to a specified order of [Localisation] :
Paris
Province-Cote-d'Azur
Autres Regions
It's Clear that this order is neither Asc Nor Desc...
Should I define a set and order according to this set ?
This is my script :
SELECT
NON EMPTY { [Measures].[Taux Occupation] } ON COLUMNS,
{ORDER (
{[hotel].[Categorie].[Categorie].ALLMEMBERS *
[hotel].[Localisation].[Localisation].ALLMEMBERS },
[Categorie].CurrentMember.Properties('KeyColumns'),DESC ) } ON ROWS
FROM [CUBE]
Thnks a lot for ur Answer
A Named Set is One Approach ...
This would be the easiest "quick fix," assuming no "natural" sort criteria exists in the data. (See my article Introduction to MSSQL Server Analysis Services: Named Sets Revisited).
You might also consider a secondary "sort attribute," (See my article Alternatively Sorting Attribute Members in Analysis Services 2005)
or perhaps even a MEMBER_VALUE (see Attribute Member Values in Analysis Services) for the sort, both of which options build it in structurally.
Get back to us with any further questions. Also, let us know of your successes in using the powerful integrated Microsoft Business Intelligence solution!
Bill
Did You Meet with Success?
Was my last month's response helpful? Let me know if I can help you further with any specific questions / findings after you've looked at trying the above...
Thanks.
Bill