我有一个看起来像这样的交叉连接
SELECT
{[Measures].[Respondent Count]} ON COLUMNS
,{
[Groups In Rows].[Group].ALLMEMBERS*
[Questions In Rows].[By ShortCode].[Option].ALLMEMBERS*
[Questions In Columns].[By ShortCode].[Option].ALLMEMBERS
} ON ROWS
FROM [cube]
我希望能够根据参数动态删除 Groups In Rows 上的交叉连接,以便在伪 mdx 中我们将拥有
SELECT
{[Measures].[Respondent Count]} ON COLUMNS
,
IIF(@UseGroups = "yes",
{ [Groups In Rows].[Group].ALLMEMBERS*
[Questions In Rows].[By ShortCode].[Option].ALLMEMBERS*
[Questions In Columns].[By ShortCode].[Option].ALLMEMBERS
},
{
[Questions In Rows].[By ShortCode].[Option].ALLMEMBERS*
[Questions In Columns].[By ShortCode].[Option].ALLMEMBERS
} ON ROWS
FROM [Cube]
这样的事情可能吗?