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

Announcements
Join us in Bucharest on Sept 18th for Qlik's AI Reality Tour! Register Now
cancel
Showing results for 
Search instead for 
Did you mean: 
Dat
Partner - Contributor III
Partner - Contributor III

Transform null values into zero

Hi all, 

Any clue on how I could transform null values ('-') into 0, without adding extra rows to my data ? 

Dat_0-1689234424243.png

 

Labels (1)
7 Replies
Chirantha
Support
Support

Hey,

 

Perhaps using ''NullAsValue'' in the load script could help as discussed here

udit_k
Partner - Creator II
Partner - Creator II

use ALT Function to your chart expression 

Example:-

alt(sum(aggr(sum({<[Export Date]={"=len([Export Date])>0"}>} 1),Item)),0)

Dat
Partner - Contributor III
Partner - Contributor III
Author

Hi @Chirantha ,

It's not working.
I also tried smtg with "if(isnull())", but it didn't work either 

Dat_0-1689237332090.png

 

Or
MVP
MVP

Unfortunately, there is no way to do this. Neither NullAsValue nor alt() will help with missing intersections in a pivot table.

Some extensions, such as Vizlib Pivot Table, let you define a custom null symbol which will override missing intersections, but in the native object there is no option of this nature available as far as I know.

Or_0-1689237665757.png

 

Dat
Partner - Contributor III
Partner - Contributor III
Author

Hi @udit_k ,

in your exemple "Export Date", is your dimension right? 

I tried, and it did not work.

Dat_1-1689237724924.png

"ID" is my dimension, and "Total CA", the field that i want to sum.

 

Dat
Partner - Contributor III
Partner - Contributor III
Author

Hi @Or ,

Can I at least show the dimension values when the measure value is null in a straight table ?

In the screen below, the ID 321 does not appear in the straight table for example.

Dat_0-1689240210671.png

 

Or
MVP
MVP

You would need to check "Include zero values" under Add-ons for this.

Or_0-1689240532929.png