Home > Archive > MS SQL Server OLAP > December 2005 > sum of sales of the last 12 periods june 1997 / june 1998 in mdx









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author sum of sales of the last 12 periods june 1997 / june 1998 in mdx
Marco

2005-12-27, 9:23 am

Hi,

What is the mdx code to show a sum of sales in foodmart 2000 of the
last 12 periods starting june 1997 / june 1998 while june 1998 is
choosen as reporting date ?

With this formula you see only the months this year:
SUM(YTD([Time]),[Measures].[Sales])

Regards, Marco

Jéjé

2005-12-27, 9:23 am

try the lastperiods function
sum(lastperiods(12),
measures.sales)

"Marco" <olap@gmsbv.nl> wrote in message
news:1135692342.933649.125560@o13g2000cwo.googlegroups.com...
> Hi,
>
> What is the mdx code to show a sum of sales in foodmart 2000 of the
> last 12 periods starting june 1997 / june 1998 while june 1998 is
> choosen as reporting date ?
>
> With this formula you see only the months this year:
> SUM(YTD([Time]),[Measures].[Sales])
>
> Regards, Marco
>



Sponsored Links





Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive | Programming forum archive

Copyright 2008 droptable.com