sample code for YTD and MAT

  • Hi can someone tell me where i could find some sample code showing how to create cumulative YTD figures and moving Annual totals within a sales cube or alternatively showing me how this can be done in Analysis services 2000. thanx any help will be much appreciated.

    ultimo 🙂

  • This was removed by the editor as SPAM

  • i have managed to sort this problem by using YTD function and for MAT using SUM function with Lag

    sample code: for YTD:

    SUM(YTD([Fiscal Time April]),[Measures].[Actual])

    sample code MAT:

    Sum([Fiscal Time April].currentmember.lag(

    iif([Fiscal Time April].CurrentMember.Level.Name = "Month",12,iif([Fiscal Time April].CurrentMember.Level.Name = "Year",1,0))):[Fiscal Time April].currentmember,[Measures].[Actual])

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

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