Qlik Community

New to Qlik Sense

If you’re new to Qlik Sense, start with this Discussion Board and get up-to-speed quickly.

Announcements
Customer & Partners, DEC. 9, 11 AM ET: Qlik Product & Strategy Roadmap Session: Data Analytics REGISTER NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
noemibuscemi01
Partner
Partner

set analysis inside if statement

hi,

how do I insert the set analysis inside the if statement?

this is my if statement 
if (isnull([BadRate.EL_Annualizzata]), '', sum([BadRate.EL_Annualizzata]))

In this way, I want that if the field is null, Qlik has to show a blank, else the field itself.

But I need that the dashboard shows the max year. 

 

noemibuscemi01_0-1608459810104.jpeg

 

at the moment I see all years and quarters (starting from 2019). I want it to show 2020 and the last quarter of 2020 4Q.

 

Thanks in advance

Labels (2)
3 Replies
noemibuscemi01
Partner
Partner
Author

I've used 

if (isnull([BadRate.EL_Annualizzata]), '',
sum({<
[BadRate.Quarter] = {$(=$(vQuarterLLP))}
>}
[BadRate.EL_Annualizzata]))

 

but the field year does not change...

agigliotti
Partner
Partner

Hi @noemibuscemi01 ,

let's try using the below expression:

sum( {< [BadRate.Quarter] = {$(=$(vQuarterLLP))} >}
if( isnull([BadRate.Mature_BR3_F12]), '', [BadRate.Mature_BR3_F12]
)
)

I hope it can help.
Best Regards
Andrea

noemibuscemi01
Partner
Partner
Author

Unfortunately it does not work! All the null values disappear, at their place zero values appear.

The point is: if I use this formula, the only quarter shown is the last one, but all the modifications related to the null values stop working.