Qlik Community

QlikView Scripting

Discussion Board for collaboration on QlikView Scripting.

paulyeo11
Valued Contributor II

How to add RangeSum for auto Accumulation with out tick on Accumulation check box ?

Hi All

I have below expression :-

Sum(

{<Year={'>$(=year(today())-2)'}>}

sales/1000)

Since As in QS , i cannot find Accumulate Tick feature. For work around I like to make use of add RangeSum into above expression ? In order to create sales by accumulation without activate Accumulation Tick Box.

Enclosed my QV Sample Doc

Paul

1 Solution

Accepted Solutions
MVP
MVP

Re: How to add RangeSum for auto Accumulation with out tick on Accumulation check box ?

Try as expression:

Aggr(
Rangesum( Above(
Sum(
{<
Year={'>$(=year(today())-2)'}>}
sales/1000)
,0,
rowno()))
,
year,(month,(NUMERIC,ASCENDING)))

5 Replies
MVP
MVP

Re: How to add RangeSum for auto Accumulation with out tick on Accumulation check box ?

Try as expression:

Aggr(
Rangesum( Above(
Sum(
{<
Year={'>$(=year(today())-2)'}>}
sales/1000)
,0,
rowno()))
,
year,(month,(NUMERIC,ASCENDING)))

paulyeo11
Valued Contributor II

Re: How to add RangeSum for auto Accumulation with out tick on Accumulation check box ?

Hi Swuehl

Many Thank it work fine in QS.

May i know why it does not display any line in QV ?

Paul

MVP
MVP

Re: How to add RangeSum for auto Accumulation with out tick on Accumulation check box ?

Are you using a QlikView version pre 12?

Have a look at

The sortable Aggr function is finally here!

for the changed syntax in QV 12 / QS 2.2.

If you need a solution for QV 11, you need to get your month field values load order in correct chronological order.

See the blog post and the referenced posts therein on how to do this.

paulyeo11
Valued Contributor II

Re: How to add RangeSum for auto Accumulation with out tick on Accumulation check box ?

Hi Swuehl

I am using ver 9 . By the way i seek help on below , similar like above :-

QS How to add accumulated line ?

I have apply what you share with me it unable to work in above expression. Hope you can help me.

Paul

paulyeo11
Valued Contributor II

Re: How to add RangeSum for auto Accumulation with out tick on Accumulation check box ?

Hi Swuehl

Thank you sharing . I read the blog post from the link you share , I think this related to Mr sunny try to help me solve and encounter the month not sort.

Paul

Sent from my iPhone

Community Browser