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

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Handling Nulls


Hi,

I have a requirement wherein I have to diregard a particular division and display the sum of sales of the other Divisions.

In the sample application attached i am trying to acheive the same by disregarding the Division 'A'

These are the following approaches used by me:

Approach 1:

=sum({<Flag={1},
Division-={'A'}>}Sales)

This approach not only  excludes division A but it also excludes the NULL divisions,but all i want is to exclude the Division A and not the NULL divisions

Approach2:

  =sum({<Flag={1},
Division={'*'}-{'A'}>}Sales)

This also gives me the result as in approach 1

Approach3:

=sum({<Flag={1}>
-<
Flag={1},Division={'A'}>}Sales)

This approach gives me the desired results.But I want to know if there is any built in function within qlikview that could be used to accomplish this requirement in a better way

13 Replies
Not applicable
Author

Thank you so much for the descriptive explaination

Not applicable
Author

Hi Michael,

Very Nice.. Very useful to me..

Is it possible to particular field level.....

Anonymous
Not applicable
Author

Instead of NULLASVALUE *;

You can do NULLASVALUE  [FieldName1],[Fieldname2],etc..;


or


Load

IF(ISNULL(Field),'<UNKNOWN>',Field) as Field;


If it is a # field than you can use the Alt() function instead.



Not applicable
Author

Yes Yes .. I got it