Skip to main content
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!

1 Solution

Accepted Solutions
jagan
Luminary Alumni
Luminary Alumni

Hi,

Please find attached file for solution.  Used dimension limits for the second dimension.

Regards,

Jagan.

View solution in original post

14 Replies
VishalWaghole
Specialist II
Specialist II

Hi Changjun,

Please find attached QVW application,

I have created one more chart in your application.

Hope it will help you.

-- Regards,

Vishal Waghole

VishalWaghole
Specialist II
Specialist II

just try with this expression :

=sum(aggr(sum(QTY),VIP,STORE))

-- Regards,

Vishal Waghole

uacg0009
Partner - Specialist
Partner - Specialist
Author

Hi vishal,

thank you for your answer,but I just want to show one store per vip,

I just want to show the most qty store, or the expression doesn't make any sense, so do you have any other idea?

thank you!

VishalWaghole
Specialist II
Specialist II

Hi Changjun,

I didn't understand your requirement,

so can you please roughly draw what type of output you want.

-- Regards,

Vishal Wagole

uacg0009
Partner - Specialist
Partner - Specialist
Author

this:

MostQtyStore3.png

Anonymous
Not applicable

See attachement

er_mohit
Master II
Master II

See the attached file

see in script also

uacg0009
Partner - Specialist
Partner - Specialist
Author

Hi Satyadev,

thanks for your help, but I think the result is not what I want, I hope the result is the same with my screenshot above.

jagan
Luminary Alumni
Luminary Alumni

Hi,

Please find attached file for solution.  Used dimension limits for the second dimension.

Regards,

Jagan.