Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
stonecold111
Creator III
Creator III

aggr(rangesum(above(sum(value1),0,rowno()),quarteryear) in script ???

Hi Qlikss,

I have 3 fileds  : quarteryear   value1    value2

                               2018-Q1            10               50

                               2018-Q2            20              40                     ...... Etc.....

 i have calculated rangesum in charCapture.JPG

t by using expression : aggr(rangesum(above(sum(value1),0,rowno()),quarteryear)

which worked fine, but i want to calculate that in script. someone suggest me.

Attached excel file and screenshot .

@sunny_talwar 

Labels (3)
1 Solution

Accepted Solutions
Vegar
MVP
MVP

Perioddata:
Load yearquarter, field1, field2
From Excel.xlsx;

NoConcatenate
Load
yearquarter,
field1,
field1 + peek('accField1') as accField1,
field2,
field2 + peek('accField2') as accField2
Resident
Perioddata /*important to get the data in correct order*/
Order by
yearquarter
;

Drop table Perioddata;

View solution in original post

3 Replies
stonecold111
Creator III
Creator III
Author

Anyone has solution?
Vegar
MVP
MVP

Perioddata:
Load yearquarter, field1, field2
From Excel.xlsx;

NoConcatenate
Load
yearquarter,
field1,
field1 + peek('accField1') as accField1,
field2,
field2 + peek('accField2') as accField2
Resident
Perioddata /*important to get the data in correct order*/
Order by
yearquarter
;

Drop table Perioddata;
stonecold111
Creator III
Creator III
Author

Thanks