Skip to main content
Announcements
Have questions about Qlik Connect? Join us live on April 10th, at 11 AM ET: SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
paulyeo11
Master
Master

why add sum(aggr into expression it return null value ?

Hi All

I have below expression work fine :-

Sum({<year = {$(=Max(year) - 1)} , month = {"<=$(=Max({<year={$(=Max(year) - 1)}, sales = {'*'}>} month))"}, rEVENUE={"rEVENUE"} >} Amount*1)/Rate/1000

I try to add sum(aggr into above expression :-

sum(aggr(

Sum({<year = {$(=Max(year) - 1)} , month = {"<=$(=Max({<year={$(=Max(year) - 1)}, sales = {'*'}>} month))"}, rEVENUE={"rEVENUE"} >} Amount*1)/Rate/1000

))

it display null value.

Paul

1 Solution

Accepted Solutions
robert_mika
Master III
Master III

You have to specify dimesion for the aggr() function.

Aggr() function

View solution in original post

3 Replies
paulyeo11
Master
Master
Author

my QVF

robert_mika
Master III
Master III

You have to specify dimesion for the aggr() function.

Aggr() function

paulyeo11
Master
Master
Author

Hi Robert

Thank you very much , it work now :-

sum(aggr(

Sum({<year = {$(=Max(year) - 1)} , month = {"<=$(=Max({<year={$(=Max(year) - 1)}, sales = {'*'}>} month))"}, rEVENUE={"rEVENUE"} >} Amount*1)/Rate/1000,SOURCE

))