Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Rank Help again

Hi,

I am continuing to struggle with a rank expression! I would like to rank agents based on the calls they have received  - this is the easy part. I only want to rank those that have received >0 calls and return that as a total (highest rank) in a column. My problem is that I can return the highest rank in a column but it is ranking the agents with 0 calls also which I want to avoid. In the attached example, I am looking to return on each row in the last column the value 14 which is the highest rank for those agents that had received >0 calls. I am currently getting 25 because it is ranking on the whole population which I want to avoid.

Thanks in advance

Haider

1 Solution

Accepted Solutions
perumal_41
Partner - Specialist II
Partner - Specialist II

Hi,

use this expression

max( Total aggr(rank(sum({<AGENT_ID={"=sum([EG_Agent_Talk_Time])<>0"}>}[EG_Agent_Talk_Time])),AGENT_ID))

View solution in original post

2 Replies
perumal_41
Partner - Specialist II
Partner - Specialist II

Hi,

use this expression

max( Total aggr(rank(sum({<AGENT_ID={"=sum([EG_Agent_Talk_Time])<>0"}>}[EG_Agent_Talk_Time])),AGENT_ID))

swuehl
MVP
MVP

Just count the number of agents with TALKTIME > 0:

=count( TOTAL {<AGENT_ID = {"=sum([EG_Agent_Talk_Time])>0"}>} AGENT_ID)