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

fmin and fmax for non aggregated data?

i have three complicated expressions i want to compare, a,b and c. I want to calculate the following: max(min(a,b),c)

The QV function max and min only work on aggregated data. I want to use max and min for data that is not in table form.

I tried creating the following variables to be used with dollar sign expansion that would serve my purpose:

let fmin = 'if($1<$2, $1, $2)';
let fmax = 'if($1>$2, $1, $2)';

They both work individually but when combined into $(fmax( $(fmin( 1,2 )), 3) ) they fail.

Does anyone have an idea of what may be wrong or how to solve this?

1 Solution

Accepted Solutions
Not applicable
Author

I think you need the RangeMax RangeMin functions. See the help for sytax, but it works for any number of non-aggregated entries.

View solution in original post

2 Replies
Not applicable
Author

I think you need the RangeMax RangeMin functions. See the help for sytax, but it works for any number of non-aggregated entries.

Not applicable
Author

Thanks, that's exactly what i was looking for.