Skip to main content
Announcements
See what Drew Clarke has to say about the Qlik Talend Cloud launch! READ THE BLOG
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

How to calculate the minimum value greater than another value?

I need to calculate the minimum value greater than a specific calculated value. How to do?

1 Solution

Accepted Solutions
sunny_talwar

May be this:

Min(Aggr(If(ora >= Min({<data>} Ora_Inizio), ora), data, Ora_Inizio, ora))

View solution in original post

5 Replies
sunny_talwar

Would you be able to share few rows of data and expected output from the data provided?

tresesco
MVP
MVP

May be using set analysis, like:

Min({<Value={'>$(vCalculatedValue)'}>}Value)

Now, the variable expansion $(vCalculatedValue) can be replaced by a value or expression you want.

Not applicable
Author

I used this expression

min({<ora={">=$(=(min(Ora_Inizio)))"}>} ora)

trying to get all the min(ora) values greater than Ora_Inizio but... since I have a Ora_Inizio different than the other rows the displayed results get me all the ora greather than the overall minimum of my current selection.

If I select only the day where the "Ora_Inizio" is 7:00, I get what I want  07:00:03

I would like to have this result also when I select all data

Thnk you

sunny_talwar

May be this:

Min(Aggr(If(ora >= Min({<data>} Ora_Inizio), ora), data, Ora_Inizio, ora))

Not applicable
Author

Great! Thanks for help