Skip to main content
Announcements
Join us at Qlik Connect for 3 magical days of learning, networking,and inspiration! REGISTER TODAY and save!
cancel
Showing results for 
Search instead for 
Did you mean: 
eduardo_dimperio
Specialist II
Specialist II

Set Analysis - Counting Null Values

Hi,

I need to count how many  meters I have when my field CONSUMO_MADRUGADA is null.

I tried:

Count({<CONSUMO_MADRUGADA-={"''"}>} DISTINCT OID_METER )

Count( {<CONSUMO_MADRUGADA={"=Len(CONSUMO_MADRUGADA)=0 "}>}DISTINCT OID_METER)

Count({<CONSUMO_MADRUGADA=-{}>} DISTINCT OID_METER)

with no sucess.

Any idea?

Labels (1)
1 Solution

Accepted Solutions
Kushal_Chawda

try below

Count({1-$<CONSUMO_MADRUGADA={"*"}>} DISTINCT OID_METER )

View solution in original post

4 Replies
Kushal_Chawda

try below

Count({1-$<CONSUMO_MADRUGADA={"*"}>} DISTINCT OID_METER )

eduardo_dimperio
Specialist II
Specialist II
Author

Hi Kush, that works  for me.

Could you please explain this line code?

I don't know if  I understand, first you select every  CONSUMO_MADRUGADA that's not null ( $<CONSUMO_MADRUGADA={"*"}>) and then subtract of the total? 

Almen
Creator II
Creator II

Try this:

 

IF(IsNull(CONSUMO_MADRUGADA)=-1 , Count(DISTINCT OID_METER))

Kushal_Chawda

@eduardo_dimperio  CONSUMO_MADRUGADA={"*"} will help to find first all the instances of  CONSUMO_MADRUGADA which are not null.  Then set identifier 1-$ help to find the null values by subtracting not null values from entire data set