Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Posting on Qlik Community is temporarily paused for some users. Thank you for patience and we'll update you soon!
cancel
Showing results for 
Search instead for 
Did you mean: 
rafaeloneil
Contributor III
Contributor III

Doubt in expression with Null field criterion

Guys, good afternoon,

I have the 2 expressions below:

To add the output: = SUM ({$ <CHANNEL = {'PROPERTY CHANNEL'},>} PORTFOLIO)

To sum the output where a field is null: = SUM (if (len (trim (REGIONAL_CARTCPVEIC)) <1, PORTFOLIO))

How do I join the same expression in the 2 criteria, type:

=SUM ({$ <CHANNEL = {'PROPERTY CHANNEL'}, len (trim (REGIONAL_CARTCPVEIC)) <1) >} PORTFOLIO)

Can you help me?

4 Replies
sunny_talwar
MVP
MVP

May be this

Sum({$<CHANNEL = {'PROPERTY CHANNEL'}>} If(Len(Trim(REGIONAL_CARTCPVEIC)) = 0, PORTFOLIO))

or create a new field in the script like this

If(Len(Trim(REGIONAL_CARTCPVEIC)) = 0, 0, 1) as NullFlag

and then use this

Sum({$<CHANNEL = {'PROPERTY CHANNEL'}, NullFlag = {0}>} PORTFOLIO)

rafaeloneil
Contributor III
Contributor III
Author

I used the Script option and it worked, Once again, thanks Sunny for the help !!

Anil_Babu_Samineni
MVP
MVP

If you got correct answer, Please close this thread by flag of correct answer

Best Anil, When applicable please mark the correct/appropriate replies as "solution" (you can mark up to 3 "solutions". Please LIKE threads if the provided solution is helpful
sunny_talwar
MVP
MVP

No problem at all, I am glad I was able to help