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

Minimum value different from 0

This expression is OK but doesn't work properly.

if([ENERGY YELDED]>0,(max([ENERGY YELDED]))-min([ENERGY YELDED]))

I want that the expression does not consider the value 0 and the a minimum value different from 0

For examplie :

ENERGY YELDED value : 

4

7

12

0

5

9

MAX = 12   MIN = 4   =  MAX - MIN = 8

Anybody can help me?

Thanks

1 Solution

Accepted Solutions
Luis_Cortizo
Former Employee
Former Employee

Another way to do the same:

=Max([ENERGY YELDED])-Min( {<[ENERGY YELDED]= {"=Min([ENERGY YELDED])>0"}>} [ENERGY YELDED])

View solution in original post

4 Replies
lironbaram
Partner - Master III
Partner - Master III

=

if(min([ENERGY YELDED ])=0,max([ENERGY YELDED ])-min([ENERGY YELDED ],2),max([ENERGY YELDED ])-min([ENERGY YELDED ]))

Luis_Cortizo
Former Employee
Former Employee

Another way to do the same:

=Max([ENERGY YELDED])-Min( {<[ENERGY YELDED]= {"=Min([ENERGY YELDED])>0"}>} [ENERGY YELDED])

Anonymous
Not applicable
Author

Thanks Icz,

works great !

Anonymous
Not applicable
Author

i tried this expression but doesn't work....

Thanks anyway