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

Announcements
Join us to spark ideas for how to put the latest capabilities into action. Register here!
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

How to eliminate zero in the Graph

Hollo Everybody,  I am using QlikSense Desktop version and i am facing a problem while developing an APP.. I would like to omit zero part of the graph to have a better  view and to see the min values and the avg values correctly, i do not want to insert a condition in the SQL part, and i did check the option "remove zero or remove null value " on the properties part, it worked for the graph only , not for the MIn and AVG,
is there any way to remove the zeros and see the effect in the graph as well as in the labels MIN and AVG ?

P:S.. you can see the scripting or the fileds assigned for each part on the picture in red colour

2018-05-17_10h42_26.jpg

16 Replies
YoussefBelloum
Champion
Champion

can you confirm that you're talking about the min and the avg of the text objects on the right ?

also, maybe I was wrong talking about aggregation..

on your graphic, I can see that the min value you're trying to get is approximatively: 6.42M

try this for the min:

=min({<DATE={"=len(trim(DATE))<>0"}>}Quantity)

Anonymous
Not applicable
Author

yes! then min value of the right-side graph, and how about the average? the same way? "

YoussefBelloum
Champion
Champion

Yes, the same way, but on average since you have sum/count

Put the same set analysis inside the sum AND inside the count

Anonymous
Not applicable
Author

bro , this formula i guess show the min of a values of  one product, since in the graph i summed all the quantity per product , so the minimum  summation!
just to make sure if this formula is applied for the minimum sum or no ?
min({<DATE={"=len(trim(DATE))<>0"}>}Quantity)

YoussefBelloum
Champion
Champion

There is only DATE dimension on your line graphic, so the value you're trying to get "6.42M" is not a value of ONE product, but it is the minimum value of all the product on that date.


you can aggregate by product, maybe you will have different result, maybe not:


=min(aggr(sum({<DATE={"=len(trim(DATE))<>0"}>}Quantity),DATE))

Anonymous
Not applicable
Author

no luck bro .. Thank you  for your help ,
do you have any idea of how to omit those zero at the begining? with scripting ? like

DATE > "01/01/2018" shoude work ?

YoussefBelloum
Champion
Champion

the best proven solution to remove all types of BLANK/NULL etc is len(trim())

it works on the front-end using a set analysis or IF statement

it also works on the back-end using IF statement on creating the field