I have a MDX query:
select NON EMPTY [TYPE].[All TYPEs].Children ON COLUMNS,
NON EMPTY [CITY].[All CITYs].Children ON ROWS
from [DW_CUBE]
where [REGION].[MADRID]
This query is showing the number of records with specific types aggregated by city, for a specific region (Madrid in this case).
CITY TYPE A TYPE B
MADRID 234 234
COLMENAR 123 234
TRES CANTOS 324 12312
I need to show the values as percentage of total records in the cube (i.e. the sum of all values displayed in the query). For example:
CITY TYPE A TYPE B
MADRID 1,74% 1,74%
COLMENAR 0,91% 1,74%
TRES CANTOS 2,41% 91,46%
Can I do this using MDX functions? Any help would be appreciated. I am using Mondrian as engine.
Thanks
Rafael