If you are unable to create a new account, please email support@bspsoftware.com

 

News:

MetaManager - Administrative Tools for IBM Cognos
Pricing starting at $2,100
Download Now    Learn More

Main Menu

first periods of moving-total

Started by Invisi, 10 Nov 2016 02:22:54 AM

Previous topic - Next topic

Invisi

I am using the function moving-total to show a trend on that with a line chart based on twelve months. Because of the nature of the function, the first periods it is still accumulating the total. This means that the line is just going up for the first eleven data points. I remember to have seen there is a way to go around this, but I can't find it. Who has the way to show the full moving total from the first data point?
Few can be done on Cognos | RTFM for those who ask basic questions...

BigChris

It's not very clear what you need, but it's probably something along the lines of running-total([YourDataField] for [Period])

hespora

You need a two-step approach.

First query: Your measure per month. This query is filtered on your reporting period *plus* 11 months prior (personally, I find it easier actually to add a full prior year). In here, you build your moving total.
Second query: Based on Query1 rather than your data source, and in here you filter for your actual reporting period. Pass through month and moving total.

Invisi

hespora, that's what I look for, thanks!

Do you know how much impact on performance it has to use the second query based on the first?
Few can be done on Cognos | RTFM for those who ask basic questions...

hespora

From the experience on my org's systems: Next to no impact on performance.

Invisi

Few can be done on Cognos | RTFM for those who ask basic questions...