Skip to main content
Announcements
Introducing Qlik Answers: A plug-and-play, Generative AI powered RAG solution. READ ALL ABOUT IT!
cancel
Showing results for 
Search instead for 
Did you mean: 
rido1421
Creator III
Creator III

Counting/Suming Null values

Hi All

I would like to create an expression to

1. Count the number of line numbers that have no Job Numbers.

2.As you can see Job number 4 and 13 have no delivery dates so these are still outstanding how do we sum the Sales value of the  job numbers without Actual delivery dates to show our outstanding value ?

     

Line NumberJob Number Sales Value Planned DeliveryActual Delivery
10010001241.46504222015/12/102015/12/10
1001001234.636542132015/12/112015/12/11
1001002-149.53578722015/12/122015/12/16
10010034634.77050782015/12/13
10010045742.96150422015/12/142015/12/14
10010056400.29473612015/12/152015/12/15
10010067618.1829322015/12/162015/12/16
10010078386.35843072015/12/172015/12/17
1001008-31.056636262015/12/182015/12/18
100100910696.62334662015/12/192015/12/25
100101011933.64706332015/12/202015/12/20
1001011-930.30531992015/12/212015/12/21
10010121389.18496872015/12/22


Your assistance is appreciated.

Thanks

1 Solution

Accepted Solutions
tamilarasu
Champion
Champion

Hi,

Use these tow expressions

1. Count({<[Job Number]={"=len(trim([Job Number]))=0"}>}[Job Number])

2. Sum({<[Actual Delivery]={"=len(trim([Actual Delivery]))=0"}>}[Sales Value])

Sample attached against your data.

View solution in original post

6 Replies
Mark_Little
Luminary
Luminary

HI,

1) Try =COUNT(IF(ISNULL([Job Number]) = -1, 1,0))

or use NullAsValue in script to add something to count in set analysis

2)Try=Sum(IF(ISNULL([Actual Delivery]) = -1,Sales Value))

Mark

tamilarasu
Champion
Champion

Hi,

Use these tow expressions

1. Count({<[Job Number]={"=len(trim([Job Number]))=0"}>}[Job Number])

2. Sum({<[Actual Delivery]={"=len(trim([Actual Delivery]))=0"}>}[Sales Value])

Sample attached against your data.

sunny_talwar

I think for the first part you can also do NullCount([Job Number]) if those two places where we see '-' are true nulls.

HirisH_V7
Master
Master

Hi,

Check this,

=Sum({<[Job Number]-={"-"},[Actual Delivery]-={''}>}[Sales Value])

Missing Fields Null.PNG

There by you will get the sum by exclusion of required Fields,

HTH,

PFA,

Hirish

HirisH
“Aspire to Inspire before we Expire!”
tamilarasu
Champion
Champion

I guess, the values are blank and not hyphen. Lets wait for the reply from Rido.

rido1421
Creator III
Creator III
Author

Thank you I have blanks and ' - ' so I had to use both concepts null and Len=0