mdx 组合聚合、periodtodate 和维度限制

mdx combination aggregate, periodtodate and dimension limitation

我有使用以下语法的 Hours ytd 度量:

    Aggregate(PeriodsToDate([Dim Time].[Fiscal Hierarchy].[Fiscal Year],
   [Dim Time].[Fiscal Hierarchy].CurrentMember),[Measures].[Hours])

我有正常的工作时间 (1):

 ([Dim Product].[Product hours type 2].&[1],[Measures].[Hours])

现在我正在尝试将这两者结合起来,以便从财政年度开始计算正常的工作时间。

尝试了以下以及更多,但所有 return NULL:

    Aggregate(PeriodsToDate([Dim Time].[Fiscal Hierarchy].[Fiscal Year],
   [Dim Time].[Fiscal Hierarchy].CurrentMember),
   ([Dim Product].[Product hours type 2].&[1],[Measures].[Hours]))

晚安,问题解决了..

  (Aggregate((PeriodsToDate([Dim Time].[Fiscal Hierarchy].[Fiscal Year],[Dim Time].[Fiscal Hierarchy].CurrentMember),[Dim Product].[Product hours type 2].&[1]),[Measures].[Hours]))