Skip to main content

QlikView App Dev

Discussion Board for collaboration related to QlikView App Development.

Announcements
An issue has been identified on Qlik Cloud hub, please visit our Status Update Page for details: GET THE LATEST
cancel
Showing results for 
Search instead for 
Did you mean: 
ankit28287
Creator
Creator

rank top 10 based on one dim having other dimension in table

HI,

                i want to create a pivot in which top 10 states as per sales (by sum group by state) also want to share products sold in each states such -

Issue.PNG

any solution  guys

7 Replies
arvind_patil
Partner - Specialist III
Partner - Specialist III

Hi Ankit,

Try Below Expression :

Your Dimension is :

State

Measure:

1.Sum({<State = {"=Rank(Sum(Sales)) <=10"}>}Sales)


2.count( Distinct Products)


Thanks,

Arvind Patil

ankit28287
Creator
Creator
Author

i need to show Products name as well

vishus913
Partner - Creator
Partner - Creator

Hi Arvind,

Can you please explain how this code works??

niclaz79
Partner - Creator III
Partner - Creator III

Hi,

As per above picture you will need to create a calculated dimension such as:

Aggr(Sum(Sales), State)

And then have the Products as a third dimension and the expression to be Count(Products) or Count(Distinct Products) depending on what you intend to show.

ankit28287
Creator
Creator
Author

i need top 10 only

ankit28287
Creator
Creator
Author

i need top 10 only and rank function is not working with second dimension

arvind_patil
Partner - Specialist III
Partner - Specialist III

I will sahre you sample qvf.