Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
chriscools
Creator II
Creator II

How to use Null value in set analysis?

Hello,

i'm trying to make an overview of all the SKU's created in our system, but missing a certain field "ProductCollectionCode".

And i'm trying to do it like this:

Count ( { $<[ProductStatus]={'Active'}, ProductCollectionCode = {''}  >}               SkuCode)

But i don't get any results and i'm sure that there are.

I'm also sure that the expression works because i get results  if i do fill in a collection code like this:

Count ( { $<[ProductStatus]={'Active'}, ProductCollectionCode = {'2017 Summer'}  >}               SkuCode)

So it must be that the NULL value is causing the expression not to work.

Any ideas how i might have a workaround in the expression without changing Null values in the script?

(The load scripts are made by an external company, which means it's costly to adapt, it takes time AND i have

a lot of these empty fields in our masterdata that i would like to work with)

Thanx for your help!!

grtz,

Chris

1 Solution

Accepted Solutions
vinieme12
Champion III
Champion III

or, this....but ideally create flags in script for better performance.


Count({$<[ProductStatus]={'Active'} >} if(isnull(ProductCollectionCode),SkuCode))

Vineeth Pujari
If a post helps to resolve your issue, please accept it as a Solution.

View solution in original post

2 Replies
sunny_talwar

So you want to Count(SkuCode) where ProductCollectionCode is null? May be this:

Count({$<[ProductStatus]={'Active'}, SkuCode = {"=Len(Trim(ProductCollectionCode)) = 0"}>} SkuCode)

or

Count({$<[ProductStatus]={'Active'}, ProductCollectionCode = e({<ProductCollectionCode = {'*'}>})>} SkuCode)

vinieme12
Champion III
Champion III

or, this....but ideally create flags in script for better performance.


Count({$<[ProductStatus]={'Active'} >} if(isnull(ProductCollectionCode),SkuCode))

Vineeth Pujari
If a post helps to resolve your issue, please accept it as a Solution.