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

Max value line

Hi all,

I got a bar chart that contains 2 expressions. Showing me the revenue over week 1 - 30

Now I would like to add a line/reference that marks the point of the max revenue. This line should move troughout the whole chart.

I Could easily just put in 740 in an expression but I then I need to adjust this when we make a revenue of 750.

This is what I got:

IF(Rank(SUM( Revenue)= 1, SUM(Revenue))/1000 = Gives me max revenue and marks it but does not create a line.

kind regards

Vincent

1 Solution

Accepted Solutions
jonathandienst
Partner - Champion III
Partner - Champion III

This is the expression to get the maximum amount per salesman (and assumes that Salesman is the only dimension on the chart):

=Max(Aggr(SUM(Revenue))/1000, Salesman))


Use this expression for the reference line.


HTH

Jonathan

Logic will get you from a to b. Imagination will take you everywhere. - A Einstein

View solution in original post

5 Replies
joshabbott
Creator III
Creator III

Are you putting this in the 'Reference Lines' or as a new expression?

This seems like something you'd want in the reference lines.

Not applicable
Author

i tried putting this in the reference line 1 min ago.

Problem is It does not aggregate the total revenue but the revenue per salesman

joshabbott
Creator III
Creator III

Well, then could it be another expression represented by a line?  You may need to take the 'if' piece out, because the rank would only be 1 one time, and would probably be only represented by a dot in your chart.  Could you post the qvw or a sample of the qvw you are working on?

jonathandienst
Partner - Champion III
Partner - Champion III

This is the expression to get the maximum amount per salesman (and assumes that Salesman is the only dimension on the chart):

=Max(Aggr(SUM(Revenue))/1000, Salesman))


Use this expression for the reference line.


HTH

Jonathan

Logic will get you from a to b. Imagination will take you everywhere. - A Einstein
Not applicable
Author

Thanks!