Qlik Community

Qlik Sense App Development

Discussion board where members can learn more about Qlik Sense App Development and Usage.

Announcements
Qlik® Product Spotlight: Discover what’s possible. Get more from our products.
See for yourself. Register today.
prashantsanchet
Contributor

qlik

How to write set analysis to get sum of sales for region where region is null;

i.e only null region sales

15 Replies
Chanty4u
Esteemed Contributor III

Re: qlik

sum({<region={" "}>}sales)

Re: qlik

May be flag the null region in the script like this

If(Len(Trim(Region)) = 0, 1, 0) as NullRegionFlag

and then this

Sum({<NullRegionFlag = {1}>}Sales)

Chanty4u
Esteemed Contributor III

Re: qlik

try this

sum({$<region={"=isnull(region)"}>} sales)

Re: qlik

Not going to work

Chanty4u
Esteemed Contributor III

Re: qlik

not tested sunny

Re: qlik

I am letting you know that it is not going to work.... and the reason is that you can't really compare a null field value within set analysis..... if it was white space, this would have worked

sum({$<region={"=Len(Trim(region)) = 0"}>} sales)

Chanty4u
Esteemed Contributor III

Re: qlik

Nice sunny let me try with the dummy data for my understanding ....

Re: qlik

Sounds like a plan... share the sample afterwards as it might help someone else

Chanty4u
Esteemed Contributor III

Re: qlik

sure sunny

Community Browser