
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Combo chart with cumulative
Hi all. Hopefully this is pretty straight forward.
So here is the script I have for my app:
SELECT
True_Churn, Retention_Target, Date_Measure, Closing_Base, Opening_Base,
(Closing_Base - Opening_Base) as Flow
from xxxxx
And here is my data table:
Opening_Base | Closing_Base | True_Churn | Retention_Target | Date_Measure |
40335 | 40838 | 7 | 88.50% | 01-01-18 |
40838 | 44219 | 549 | 85.90% | 01-02-18 |
Each month I'm going to update the table with the previous month's data.
I want to product a combo bar/line graph showing each month's Flow number as the bars, with the cumulative month on month Flow as the line.
The basics are pretty, well, basic:
- Dimension = month(Date_Measure)
- First measure for the bars = sum(Flow)
But how do I add a cumulative line graph to it please?
I have tried
if(Sum(if(year(Date_Measure)=2018, Flow,0))>0, rangesum( above( sum(if(year(Date_Measure) = 2018,Flow,0)),0,rowno())), null)
But it's returning a figure for Feb of 27,188 (no idea how it's got that) not the expected 3,884.
- Tags:
- combo
- cumulative
Accepted Solutions

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi - sorted. I had made it far too complicated. Just a straight
Rangesum(above(sum(Flow),0,RowNo()))
Has done it.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
can you attach some data ? 12 lines with 2 columns: Flow and Date_measure

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi Youssef
As attached - it's my actual data. Thanks!

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi - sorted. I had made it far too complicated. Just a straight
Rangesum(above(sum(Flow),0,RowNo()))
Has done it.
