Add 7 to a member in MDX?

  • Can some one provide me with an example to add 7 days onto a parameter, an example value of which is as follows;

    [CRM DIM Time].[Date].&[20080111]

    I have a feeling that this needs to be within a hierarchy in order to navigate to different positions?

  • So far I have tried using the hierarchy members with various combinations of the following;

    MEMBER [Measures].[ParameterValue7Days] AS '[CRM DIM Time].[Year - Quarter - Month - Day Hierarchy].[date].lag(7)'

    MEMBER [Measures].[ParameterValue7Days] AS '[CRM DIM Time].[Year - Quarter - Month - Day Hierarchy].currentmember.lag(7)'

    MEMBER [Measures].[ParameterValue7Days] AS 'ANCESTOR( [CRM DIM Time].[Year - Quarter - Month - Day Hierarchy], 7)'

    These all return null

  • Got it in the end !!

    ParallelPeriod ([CRM DIM Time].[Date].[Date], -6 , STRTOMEMBER(@ReportDay) )

Viewing 3 posts - 1 through 3 (of 3 total)

You must be logged in to reply to this topic. Login to reply