This field is required.
Only these extensions are allowed(.jpg, .JPG, .jpeg, .JPEG, .gif, .GIF, .png, .PNG)
Tags cannot contain the characters ' /, \\, #, ?, or ; >,< '
Only these extensions are allowed(.zip,.ZIP,.pdf,.PDF,.qvf,.QVF,.qvw,.QVW)
If you’re new to Qlik Sense, start with this Discussion Board and get up-to-speed quickly.
So I want to count the entries where the state is 'CRIT', but distinct the entries with the same names.It is a bit like this:
count(DISTINCT[name]) but with the condition If(state='CRIT', 1, 0))
If(state='CRIT', 1, 0))
You have all the bits you need there, just need to put them together.
The thing you can use to your advantage is that the COUNT function (DISTINCT or otherwise) does not count NULLs, so you just have to put a null in where it is not the type you wish to count:
count(DISTINCT If(service_state='CRIT', alias, null()))
That should do the trick.
View solution in original post
Try to use set analysis where possible because it performs way better than IFs.
In your case:
Thank you very much @stevedark !!! helped me a lot
D'oh! Focussed on answering the question in hand that I missed that there was a much better way of achieving the same thing.
Thanks for posting a better way.