Skip to main content
Announcements
See what Drew Clarke has to say about the Qlik Talend Cloud launch! READ THE BLOG
cancel
Showing results for 
Search instead for 
Did you mean: 
scottmc68
Partner - Contributor
Partner - Contributor

Set analysis is being ignored when using the RANK function

Hello,

I'm using a piece of script that counts the number of employee names that have a RANK between 0 and .10 when the Manager Type = 'IP'.  The script is counting correctly.  However, when the user selects a Manager Type other than 'IP', the chart displays all zeros.  The appropriate behavior is to always display data for Manager Type = 'IP' regardless of what manager type is selected from the filter.  A few of has have looked at this, but we haven't figured out what's missing.

Any thoughts?

 

sum({<[Manager Type]={'IP'}>}
Aggr({<[Manager Type]={'IP'}>}
if(
(Rank(Total -
aggr(Count({<[Manager Type]={'IP'}>} [Hospital Account Id]),[In Progress Laborlytics Name])
/
aggr(sum({<[Manager Type]={'IP'}>} [Productive Hours]),[In Progress Laborlytics Name]),1)
/
count({<[Manager Type]={'IP'}>} total [In Progress Laborlytics Name]))
> 0 and
(Rank(Total -
aggr(Count({<[Manager Type]={'IP'}>} [Hospital Account Id]),[In Progress Laborlytics Name])
/
aggr(sum({<[Manager Type]={'IP'}>} [Productive Hours]),[In Progress Laborlytics Name]),1)
/
count({<[Manager Type]={'IP'}>} total [In Progress Laborlytics Name]))
<=.10,
count({<[Manager Type]={'IP'}>} [In Progress Laborlytics Name])
)
,[In Progress Laborlytics Name]
,[Manager Type]
,[In Progress Coder Manager]
))

Labels (1)
1 Reply
Lisa_P
Employee
Employee

You need to add a few more {<[Manager Type]={'IP'}>} for your aggr
aggr({<[Manager Type]={'IP'}>} Count ...
aggr({<[Manager Type]={'IP'}>} sum ..
to ignore selections in all of the aggregations