MDX 中的简单除法

问题描述

尝试使用 PanelSoldDays 和 DateDaysInMonth 达到 PanelSoldMonths 率。但是,在进行这个简单的除法时,我得到了空值的返回。

PanelSoldMonths = PanelSoldDays / DateDaysInMonth

WITH MEMBER [Measures].PanelSoldMonths AS 
IIF ([In Charge Date].[In Charge Date Days in Month]= 0,NULL,([Measures].[Panel Sold Days] / [In Charge Date].[In Charge Date Days in Month].Children))
    SELECT 
    {[Measures].[Total Net Net Revenue],[Measures].[Panel Sold Days],[Measures].PanelSoldMonths}
ON COLUMNS,NON EMPTY
    ([In Charge Date].[In Charge Year].Children,[In Charge Date].[In Charge Date Days in Month].Children)
ON ROWS
    FROM [Combined Sales]
    WHERE [Asset Info].[Format Group L2].&[Digital] 

enter image description here

解决方法

替换

[In Charge Date].[In Charge Date Days in Month]= 0

[In Charge Date].[In Charge Date Days in Month].currentmember.Properties ("Member_Value",TYPED)=0