Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Calculations of YTD

input fields:

   

Country15-Jan15-Feb16-Jan16-Feb
UK100200500600
India245254550650

I have the fileds like above and I need to out put like below , please help me to get the below result:

  Output:  

Country15-Jan15-Feb16-Jan16-Feb
UK1003005001100
India2454995501200
4 Replies
boraste-sagar
Contributor III
Contributor III

Hi Rachana,

You can use the concept of running total in the expressions to add the total of previous month t=with current month using expressions

for your output of 15-Feb use this expression

=Sum([15-Jan])+Sum([15-Feb])

same for 16-Feb and so on

=sum([16-Jan])+Sum([16-Feb])Solution.png

priyalvp24
Creator
Creator

hi,

Try this

At Script Level:

num(Month(datefield)) as DocMonth,

Year(datefield) as DocYear

At Front.

Country as Dimension.

In measure write below set analysis

sum({<DocMonth={"$(=max({<DocYear={'$(=max(DocYear))'}>}DocMonth))"}>}     [Measure Field])

Thanks,

Priyal

balabhaskarqlik

Try this:

RangeSum( Before(TOTAL Sum(Sales),0,ColumnNo(TOTAL)))

balabhaskarqlik