Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Suppressing zero values

I have two fields (Orders, Receipt ) put into a chart as an expression but it is just pulling it from a field in a table that has both of these values.  Sometimes, there are orders during certain weeks for some products but other times, it could be zero.

What is the best way to make it so that they do not show when the values for those fields are 0. I tried to 'Suppress 0 values' under the presentation tab for those two specific fields but they don't do anything.

14 Replies
MK_QSL
MVP
MVP

suppress when value is null in dimension tab and suppress zero values in presentation tab...

try both...

avinashelite

Hi Jmathew,

Can you share your expression or app

sujeetsingh
Master III
Master III

You need to check the options first and if it again exist then you need to handle nulls in data model

Not applicable
Author

Yes, both options to suppress missing and zero values are checked but I still see them. I think I know why the options are not working. It is because for each product, I have a transportation cost that is calculated and they exist whether there is an order or not.

The expression is just =orders which is the field name but they are associated to  products and transportation costs so certain weeks, those products might not have orders but because they have a transportation cost, the options to suppress missing and zero values will not work. Any other idea on how to make this work?

This is an example of my chart:

Product, Orders, Receipt, Transportation_Cost

A1, 0, 0, 5

Not applicable
Author

I'm using an expression (FirstSortedValue({<TransportationCost = {">0"},Location, [TransportationCost],1) to calculate the cheapest transportation cost.

What expression can I use to say if orders=0 AND receipt=0, then transportation cost should be null?

fsimoes81
Partner - Contributor III
Partner - Contributor III

Are you tried to add Orders -={0}, Receipt -= {0} in your expression?


TransportationCost = {">0"},Orders -= {0}, Receipt-= {0}



Not applicable
Author

I tried to do that and it is still showing the records which have 0 orders. Any other ideas on how to not show a record if a certain field is 0?

fsimoes81
Partner - Contributor III
Partner - Contributor III

Look attached example. On my example the expression works fine, maybe I don't understood correctly your problem

Not applicable
Author

Thanks for your help Fabio but it is not exactly what I'm looking for.

Your sample does not show Product A3. I only want it to ignore the the record if BOTH order and receipt are 0.