Skip to main content
Announcements
Qlik Connect 2025: 3 days of full immersion in data, analytics, and AI. May 13-15 | Orlando, FL: Learn More
cancel
Showing results for 
Search instead for 
Did you mean: 
Jagveer
Contributor III
Contributor III

Calculate top 10 vs total in staright table

Hi Community

i have a staright table which displays top 10 value for a combination of 2 dimensions (the dimensions are hierarchical).

now i want to calculate the percentage of these top 10 vs the total value and show that may be in a text box next to the table

can someone please suggest how to do it?

4 Replies
Frank_Hartmann
Master II
Master II

please share a small sample qvw with some sample data to work....

Jagveer
Contributor III
Contributor III
Author

I am attaching an excel with the data set.

It contains year over year comparison for sale of each customer. i have a straight table that shows 2019, 2020 sales and YoY change and the table  shows top 10 customers based on Year over year change. the second set shows total data.

What i want to do is calculate the percentage of top 10 year over year change vs total sales of 2020

(Sum of top 10 YoY change)/(Total sales in 2020)

Frank_Hartmann
Master II
Master II

see attached

Jagveer
Contributor III
Contributor III
Author

Thanks for you reply, but this does not solve my issue. my fault actually as i was not clear earlier.

i have the data for 2019 and 2020 combined. then i use aggr function for splitting them into column by year and then i calculate Year over Year change. Your solution assumes the year data is separated which it is not.