简体   繁体   English

缺少度量值(计算所得成员)

[英]Missing value of measure (calculated member )

I've got a data warehouse which is underlying database of OLAP cube. 我有一个数据仓库,它是OLAP多维数据集的基础数据库。 When I run query like that: 当我运行这样的查询时:

SELECT  dimS.Attribute2,SUM(fact.LastValue)
FROM FactTable fact
JOIN DimS dimS ON fact.DimSKey = DimS.DimSKey
GROUP BY DimSKey.Attribute2 

I can see that all existing Attribute2 at dimS table have corresponding rows at fact table. 我可以看到dimS表上所有现有的Attribute2在事实表上都有对应的行。

On the other hand I've got a calculated measure: 另一方面,我有一个计算得出的度量:

CREATE MEMBER CURRENTCUBE.[MEASURES].[MyMeasure]
AS ([Measures].[FactTable - LastValue]
, [DimS].[S Hierarchy].[All].[Hierarchy SomeName]
, [DimS].[Category].[All]
, [DimS].[Question].CurrentMember
, [CimC].[Status].&[Active]
),DISPLAY_FOLDER='Folder',VISIBLE = 1;

and when running below MDX: 在MDX以下运行时:

SELECT
{ [Measures].[MyMeasure] } ON COLUMNS, 
{ ([Survey].[Attribute2].ALLMEMBERS ) }  ON ROWS 
FROM [MyCube]

I can see that 2 of Attribute2 have no values (null) assigned to them. 我可以看到Attribute2中的2没有分配任何值(空)。

What can cause issue like that (DimS and cube has been just processed fully)? 是什么会引起这样的问题(DimS和多维数据集已被完全处理)?

Found the rootcause. 找到了根本原因。

the reference in MDX definition of calculated measure to [DimS].[S Hierarchy].[All].[Hierarchy SomeName] is another calculated measure where actually we have hardcoded values within dimension hierarchy. MDX定义中的计算量度对[DimS]。[S层次结构]。[全部]。[层次结构SomeName]的引用是另一种计算量度,实际上我们在维层次结构中具有硬编码值。 And for [Attribute2] this condition is not met. 对于[Attribute2],不满足此条件。

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

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