Skip to main content
Announcements
Join us at Qlik Connect for 3 magical days of learning, networking,and inspiration! REGISTER TODAY and save!
cancel
Showing results for 
Search instead for 
Did you mean: 
uacg0009
Partner - Specialist
Partner - Specialist

Why the aggr(firstsortedvalue) dimension doesn't affect the expression?

Hi all,

I have a question like what I said on the topic, I feel it is strange.

I want to calculate the most qty store per vip. and I have data like this:

MostQtyStore1.png

and I did a chart to calculate that using aggr firstsortedvalu in dimension like this:

MostQtyStore2.png

but the expression(QTY) is not 8 for A, but 11 for A, so I feel it is strange, why the second dimension doesn't affect the expression?

or do I need to use other statement to calculate that?

please help, and the attached file is the qvw. Thank you so much!

14 Replies
Anonymous
Not applicable

Hi,

Please check the enhanced version. Hope this helps you.

qty.PNG.png

uacg0009
Partner - Specialist
Partner - Specialist
Author

Hi Mohit,

thanks for your help, the result is what I want, but I don't want to change the script, do you have any other idea to solve this problem?

thank you !

uacg0009
Partner - Specialist
Partner - Specialist
Author

Hi Satyadev,

thanks again, the result is great for me, but actually I don't want to modify the script, I think Jagan's method works.

thank you so much,

uacg0009
Partner - Specialist
Partner - Specialist
Author

Hi Jagan,

thank you so much for you answer, that's what I want. But if I change the request about most qty to most order to also calculate the sum(qty), does that will work?

jagan
Luminary Alumni
Luminary Alumni

Hi,

This will work just change the expression.Count(ORDER) it works.

Regards,

Jagan.