Skip to main content
Announcements
Have questions about Qlik Connect? Join us live on April 10th, at 11 AM ET: SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
madnanansari
Creator
Creator

Line graph with Cumulative figures

I have developed a line graph where I plot the Running Sales & Target for the month for each day. So as u progress the month; the chart shows an increasing sales vs target lines.

The formula for sales is as below:

RangeSum(Above(Sum(Sales)),0, RowNo(TOTAL)))

The graph was perfect.

The user comes with a requirement that he need to show sales with green color and the target with blue color. So I tried to develop the graph using value list. Value list dont bring the right graph. I observe that the RangeSum function in not working properly in the value list.

Any suggestions?

SalesVSTarget.jpg

8 Replies
sarvesh
Creator III
Creator III

Hi..Adnan,

Write this type "if(Year='2014',Red(),Green())" of syntax in expression.

Regard's

Sarvesh Srivastava

Chanty4u
MVP
MVP

or try this

sum(Sales) / Sum(TOTAL <$(=GetCurrentField(Dimension))> sales)

sunny_talwar

Would you be able to share a sample to look at what you had initially and what you have now?

madnanansari
Creator
Creator
Author

issue is not coloring. Issue is that the RangeSum function returns wrong values. The graph is not cumulative.

sarvesh
Creator III
Creator III

Try this syntax if you have problem in Range sum function

RangeSum(first_expr[, Expression])

madnanansari
Creator
Creator
Author

how to copy the App here?

madnanansari
Creator
Creator
Author

I dont have the option to attach a file here. I have openned another discussion where I am able to attach the file.