Qlik Community

QlikView App Development

Discussion Board for collaboration related to QlikView App Development.

Highlighted
Not applicable

count null and non null values problem

Hi im trying to count all "LanID" where they have 2 or less then 2 " DocName"  and the null values for those that dont have any "DocName"

=count(DISTINCT {<LanID = {"=count(distinct DocName)<=2"}>}LanID)

+  count(DISTINCT LanID) -count(DISTINCT {<DocName = {"*"}>}LanID) 

This is my expression

The problem is when im trying to implement a YTD , MTYD and LYTD to this, it gets tricky,

For example :

All LanIDs that have <=2 DocNames including 0 and null value is = 198 LanIDs

When i press the current Year = 136 LanIDs

When i press current Year and choose Oct and Sep = 146 ,

How  could this be ?

I have tried with NullCount and adding the LanIDs manually, but wont work..

Any Help would be much appriciated .

1 Reply
sujeetsingh
Honored Contributor III

Re: count null and non null values problem

Post a sample plz