COGNOiSe.com - The IBM Cognos Community

IBM Cognos 8 Platform => COGNOS 8 => Report Studio => Topic started by: Sarayucog on 19 Jan 2012 05:30:56 AM

Title: How to calculate Change from Jan to remaining months
Post by: Sarayucog on 19 Jan 2012 05:30:56 AM
Hi Gurus,

I have a crosstab with Month on column and measures on rows. Here I want to calculate the change from January month to rest of the months.

Here Month query item contains data as 201101, 201102, 201103, etc...

EX: I want to find the difference between the current month and Jan month.

I have a calculation as below

(Current month measure - previous month measure) / Previous month measure)

EX: (Feb Month Measure - Jan Month Measure) / Jan Month Measure

(Mar Month Measure - Jan Month Measure) / Jan Month Measure

(Apr Month Measure - Jan Month Measure) / Jan Month Measure

NOTE: previous month measure will always contains Jan month data only.

Like above I need to calculate Change from Jan month to other months.


So here we have to find how to store each and every month measure in a data item dynamically.

How to resolve this... Please let me know the result.
Title: Re: How to calculate Change from Jan to remaining months
Post by: techicognos on 24 Jan 2012 10:23:37 AM
convert your time Query subject into DMR and try playing with prevMember and CurrentMember functions. You should get it.
with this approach you also see performance improvement.