这里我们共有14行,我需要多一列(RowCount-Column name) 每个单元格包含14(信誉)表示总行数。
以下是查询
WITH MEMBER DimName AS [DimClinic].[Provider Key].CurrentMember.Member_Caption
MEMBER DimKey AS [DimClinic].[Provider Key].CurrentMember.Member_Key
SELECT {[Measures].DimKey ,
[Measures].DimName ,
[Measures].[DrPatientKeyCnt]} ON COLUMNS ,
NonEmpty([DimClinic].[Provider Key].[Provider Key])ON ROWS
FROM [PopulationReportCube]
答案 0 :(得分:0)
WITH
MEMBER DimName AS
[DimClinic].[Provider Key].CurrentMember.Member_Caption
MEMBER DimKey AS
[DimClinic].[Provider Key].CurrentMember.Member_Key
MEMBER RowCount AS
Count
(
NonEmpty
(
[DimClinic].[Provider Key].[Provider Key]
,[Measures].[DrPatientKeyCnt]
)
)
SELECT
{
[Measures].DimKey
,[Measures].DimName
,[Measures].[DrPatientKeyCnt]
,[Measures].[RowCount]
} ON COLUMNS
,NonEmpty([DimClinic].[Provider Key].[Provider Key]) ON ROWS
FROM [PopulationReportCube];