Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Want to see what's currently in public preview? We've pulled it all together in one place. Check it out here
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

cumulative sum in line chart

Hello

I have an expression I need to show in a line chart this way  ( i have two dimensions, country and time (hierarchy Month->day->hour)

The cumul has to be 100% at all  times

and with the expression (sum(flag)/sum(total flag))

The cumul is bellow 100% how can I make it 100% at all times

Thanks

1 Solution

Accepted Solutions
Not applicable
Author

hello

figured it out   the answers is

sum(sales)/sum(Total<Month,Day,hour> sales)

View solution in original post

5 Replies
Chanty4u
MVP
MVP

post sample qvw?

Not applicable
Author

hello

figured it out   the answers is

sum(sales)/sum(Total<Month,Day,hour> sales)

rwunderlich
MVP
MVP

You will need to include the Dimension fieldname in TOTAL to get 100% per interval. Because you are using a Drill group, use a $() to insert the correct fieldname.

sum(flag) / Sum(TOTAL <$(=GetCurrentField(TimeGroup))> flag)

-Rob

http://masterssummit.com

http://qlikviewcookbook.com

rwunderlich
MVP
MVP

That looks like easier syntax than my solution

-Rob

Not applicable
Author

Hello Rob,

actually there is no GetCurrentField() in Qliksense which could have been really helpful for many other developments.

Thanks for your answer