Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
devarasu07
Master II
Master II

Rank

Hi All,

Please refer to the attached sample document, Can the individual article be arranged by their best color (based on Qty Sold Week 4)  at the top and worst color at bottom?  if i add additional ranking column then it's giving correct result. But i do not want to display the additional column. Is there anyway that the sorting logic be inserted into the color sort expression. Tried below expression in "Color" sort, but didn't give the expected output. kindly advise. Thanks


=aggr(Rank(sum([Qty_Sold WK_4])),ArticleNo,Color)

1.jpg

8 Replies
sunny_talwar

This?

Capture.PNG

Replaced Color with a calculated dimension:

=Dual(Color, Aggr(Rank(Sum([Qty_Sold WK_4])),ArticleNo,Color))

vishsaggi
Champion III
Champion III

Sunny, in his first image for second article no - The colors are BLACK, RED and NUDE?

Yours say BLACK, GREY and TAUPE? Just wondering ?

sunny_talwar

Good point..... Let me check

sunny_talwar

May be this

Where I added a new expression

=Rank(Sum([Qty_Sold WK_4]))

and then sort by y-value

and used the Macro to change the width of the first column to 0

Capture.PNG

Anonymous
Not applicable

I opened the qvw and the below image is a result of your qvw. Where is the issue. I am a bit confused.

vishsaggi
Champion III
Champion III

Hello Imad,

He does not want to use the Dimension field Name Rank by best Sold in that table. Remove that Field and see ?

devarasu07
Master II
Master II
Author

Hi Sunny,

Thanks. your second approach working fine with correctly. last time i have tried to configured macros and it's not working. is there any way to avoid macros here. thanks

below issue facing while configuring and testing via IE plug in.

Exporting QV objects to a Excel document using macros?

Regards, Deva

sunny_talwar

Its a one time macro... You can remove it once you have squeezed the column to 0 width. You never have to use or see it again.