简体   繁体   English

MDX帮助SSRS查询设计器MDX计算的成员和MDX运算符过滤器表达式

[英]MDX Help SSRS Query Designer MDX Calculated Member & MDX Operator Filter Expression

I have 2 questions in the SSRS Query Designer for my SSAS tabular model. 我的SSAS表格模型在SSRS查询设计器中有两个问题。 I create a calculated Member column that basically says, IF this other column = "Last Invoice Date", put "Last Invoice Date" as the value, otherwise, put a different column's value in, "FiscalMonthLastDay": 我创建了一个计算所得的Member列,该列基本上说,如果这另一列=“ Last Invoice Date”,则将“ Last Invoice Date”作为值,否则,将另一个列的值放入“ FiscalMonthLastDay”:

IIF([Invoice Date].[Relative Date].CurrentMember.MEMBER_CAPTION ="Last Invoice Date", "Last Invoice Date", [Invoice Date].[FiscalMonthLastDay].CurrentMember.MEMBER_CAPTION)

When i drag that new field in, it works but its creating extra rows in my results. 当我将新字段拖入时,它可以工作,但会在我的结果中创建额外的行。 I added before & after screen shot (erased some sensitive data). 我在屏幕快照前后添加了(删除了一些敏感数据)。 I can't figure out how to get it to not show the extra rows? 我不知道如何使它不显示多余的行?

Before: 之前: 在此处输入图片说明

After: 后:

在此处输入图片说明

My 2nd question is, i would then like to filter my data set to only where this new calculated member matches another column. 我的第二个问题是,然后我想将数据集过滤到仅此新计算成员与另一列匹配的地方。 So I am doing the MDX operator in the filters section and thought something like this would work, but i can't get it to (its the same formula as above): 因此,我在“过滤器”部分中进行了MDX运算符,并认为类似的方法可以工作,但我无法达到(与上述相同的公式):

在此处输入图片说明

If anyone knows where to get some good examples of how this MDX operator is used, that would be great ! 如果有人知道从何处获得有关如何使用此MDX运算符的良好示例,那就太好了!

Thanks ! 谢谢 !

I don't understand this: 我不明白这一点:

[Invoice Date].[Relative Date].CurrentMember.MEMBER_CAPTION ="Last Invoice Date"

Looking at your screenprints [Relative Date] is a date - so how can MEMBER_CAPTION be equal to "Last Invoice Date" ? 查看您的屏幕截图, [Relative Date]是一个日期-那么MEMBER_CAPTION如何等于“上一个发票日期”?

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM