Qlik Community

New to Qlik Sense

Discussion board where members can get started with Qlik Sense.

Announcements
Announcement: Certain actions are currently causing a Page Not Found error. This is a known issue and we are working with the platform vendor to investigate and resolve it.
Highlighted
ndeeleysww
Contributor

Top 10 in Set Analysis

Hi there,

It's very easy to create a Top 10 in a table in QlikSense by using the Fixed Number limitation on the dimension,but now I need to carry the top 10 total through to a KPI.

Does anyone know how I apply a top 10 to set analysis to get my total? Here is my set analysis so far:

Count({1<Date={'>=$(=Date($(vTodaysDate)))'}, OpsFunction={'Drinking Water', 'Waste Water'}, DataSource={'Alarms'}, alarm_status={3} >} AlarmCount)

Thanks for your help!

Neil

4 Replies

Re: Top 10 in Set Analysis

What all are your dimensions? Is there a single dimension or multiple dimension in your chart where you are showing the top 10?

Re: Top 10 in Set Analysis

May be you can try this if there are multiple dimensions:

Sum(Aggr(If(Rank(Count({1<Date={'>=$(=Date($(vTodaysDate)))'}, OpsFunction={'Drinking Water', 'Waste Water'}, DataSource={'Alarms'}, alarm_status={3} >} AlarmCount) < 11, Count({1<Date={'>=$(=Date($(vTodaysDate)))'}, OpsFunction={'Drinking Water', 'Waste Water'}, DataSource={'Alarms'}, alarm_status={3} >} AlarmCount)), ListAllYourDimensionsHereSeparatedByComma))

ndeeleysww
Contributor

Re: Top 10 in Set Analysis

There’s only one dimension, but it’s a concatenated dimension made up of 4 dimensions, which identify a single alarm:

Process & & Asset &

Re: Top 10 in Set Analysis

Would it be possible to combine those 4 in the script: If you can, then the expression won't need Aggr() statement:

Count({1<Date={'>=$(=Date($(vTodaysDate)))'}, OpsFunction={'Drinking Water', 'Waste Water'}, DataSource={'Alarms'}, alarm_status={3},


Key = {"=Rank(Count({1<Date={'>=$(=Date($(vTodaysDate)))'}, OpsFunction = {'Drinking Water', 'Waste Water'}, DataSource={'Alarms'}, alarm_status={3}>} AlarmCount)) < 11"}


>} AlarmCount)

Here Key is the combination of the 4 fields created in the script