【发布时间】:2016-12-27 15:51:44
【问题描述】:
我正在使用 AdventureWorksDW2014。我创建了 2 个度量,但是当我应用过滤器时,它们的行为并没有达到预期的效果。
我有 2 个表 FactInternetSales 和 DimCustomer。它们通过 CustomerKey 链接。 我有 2 个计算量度。一项衡量标准(所有性别)总结了运费。
All Gender Freight = CALCULATE( sum(InternetSale[FactInternetSales.Freight]))
另一种衡量方式总结了只有男性的运费
Male Measure Freight =
CALCULATE (
SUM ( InternetSale[FactInternetSales.Freight] ),
Customer[DimCustomer.Gender] = "M"
)
现在,如果我使用 Power BI 或 Power Pivot Excel 查看所有性别的第一个度量。我看到了这个。这是我所期望的。
Gender All Gender
F 370341.79
M 363627.8142
对于第二个措施,我无法解释的是,我预计女性的总运费为零,因为我没有将其包含在我的措施中。
Gender All Gender
F 363627.8142 --Should be 0
M 363627.8142
【问题讨论】:
标签: ssas powerpivot powerbi dax