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

Announcements
April 13–15 - Dare to Unleash a New Professional You at Qlik Connect 2026: Register Now!
cancel
Showing results for 
Search instead for 
Did you mean: 
JoseGarcia
Creator III
Creator III

KPI default selection

Hi all, 

I am not a hundred percent if I am doing the following correctly:

I am trying to set a measure expression to show that if no selection is made, default value selection is set to High Risk, if other selection is made, the the KPI updates to selected risk.

Can anyone assist?

Thank you !

4 Replies
lironbaram
Partner - Master III
Partner - Master III

hi 

it should be something like 

if(getselectedcount(RISK_FIELD)=0, sum(IF(RISK_FIELD='high risk',Value)),sum(Value))

JoseGarcia
Creator III
Creator III
Author

Thank you very much for your reply.

Here is my measure expression, but it is giving me a syntax error. where am I going wrong?

if(getselectedcount(ListItemsFromID_Riskdescription)=0, sum(IF(ListItemsFromID_FullImpact='High',Value)),sum(Value))

 

Details:

Chart type: Treemap

Dimension: ListItemsFromID_Riskdescription

Measure: if(getselectedcount(ListItemsFromID_Riskdescription)=0, sum(IF(ListItemsFromID_FullImpact='High',Value)),sum(Value))

lironbaram
Partner - Master III
Partner - Master III

hi 

i just checked on similar expression syntax and it's working , 

so it's something specific to your syntax , i don't see anything wrong 

can you post sample data 

JoseGarcia
Creator III
Creator III
Author

here is a snapshot of the data, and an extract of the data file