我试图从包含省和州的维度 [Ship To State] 中排除未知。
第一个表达式抛出了省和州,我不知道为什么 -
此 mdx 仅列出州(不包括未知,出于某种原因,不包括省):
WITH
MEMBER measures.ParameterCaption as [Ship To].[Ship To State].currentmember.member_caption
MEMBER measures.ParameterValue as [Ship To].[Ship To State].currentmember.uniquename
SELECT {measures.ParameterCaption, measures.ParameterValue} ON COLUMNS,
FILTER([Ship To].[Ship To State].children,
[Ship To].[Ship To State].currentmember<>[Ship To].[Ship To State].&[Unknown]
) ON ROWS
FROM [Invoiced Orders]
此 mdx 正确列出了州和省,并排除了未知:
WITH
MEMBER measures.ParameterCaption as [Ship To].[Ship To State].currentmember.member_caption
MEMBER measures.ParameterValue as [Ship To].[Ship To State].currentmember.uniquename
SELECT {measures.ParameterCaption, measures.ParameterValue} ON COLUMNS,
FILTER([Ship To].[Ship To State].children,
measures.ParameterCaption <> "Unknown"
) ON ROWS
FROM [Invoiced Orders]