Ssas MDX上的百分比计算

Ssas MDX上的百分比计算,ssas,mdx,olap,Ssas,Mdx,Olap,我是MDX查询的新手,我正在尝试在每一行中添加一个参与百分比。以下代码: SELECT {[Measures].[Client Interventions Count]* [Dim Intervention Attendance].[Attended].Children} ON COLUMNS, [Dim Date].[Calendar].[Month Name] ON ROWS FROM [Client Intervention] 产生以下结果: 如何对每行执行计算?例如,第一行2007年1

我是MDX查询的新手,我正在尝试在每一行中添加一个参与百分比。以下代码:

SELECT {[Measures].[Client Interventions Count]* [Dim Intervention Attendance].[Attended].Children} ON COLUMNS,
[Dim Date].[Calendar].[Month Name] ON ROWS
FROM [Client Intervention]
产生以下结果:

如何对每行执行计算?例如,第一行2007年11月,总客户干预计数=68,因此百分比计数应为57/68%


有什么想法吗??谢谢

使用计算会员-您可以找到几个示例。查询的思路如下:

WITH MEMBER [Dim Intervention Attendance].[Attended].[%] AS
    ( [Dim Intervention Attendance].[Attended].[Attented],
       [Measures].[Client Interventions Count] )
  / ( [Dim Intervention Attendance].[Attended].[Not Attented], 
      [Measures].[Client Interventions Count] )

SELECT  
  [Measures].[Client Interventions Count] 
   * { [Dim Intervention Attendance].[Attended].[%], 
       [Dim Intervention Attendance].[Attended].Children } ON COLUMNS,

  [Dim Date].[Calendar].[Month Name] ON ROWS

FROM [Client Intervention
]