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: 
Not applicable

Ten first products in a pivot table

Hi everybody,

   I have some sales data by family product and product. I want to extract and represent in a pivot table the ten first product of each family product.

In a straight table, it is quite easy with the dimension limits but in a pivot table it is slightly harder.

I tried to filter my 10 first item with a rank but other products are still visible in my straight table.

Have you a idea to remove those with null value in sales ?

I don't understand why there are still shown as suppress missing and suppress zero values are selected.

I join the application example.

regards

stephane

1 Solution

Accepted Solutions
tresesco
MVP
MVP

4 Replies
tresesco
MVP
MVP

PFA

Not applicable
Author

thanks for your answer.

I'm quite surprise that the rank() function can work inside the aggr().

For me, the result of rank() inside the aggr() function should always return 1 ?!

tresesco
MVP
MVP

Aggr is just aggregating the records on dimension, until there would be multiple records/aggregated amounts there is a possibility that rank() would not return always 1. Think like this: taking Family, Product in dimension and using rank() on them is similar to using Aggr(Rank(..) , Family, Product). Isn't it?  I know that the explanation could have been better, but hope this helps you to fall on the right path of thinking.

Not applicable
Author

You're right.

Actually, the rank() function still works at the aggregated level. That was the reason of my incomprehension.

Thanks again.

stéphane