COGNOiSe.com - The IBM Cognos Community

IBM Cognos Analytics Platform => Cognos Analytics => Reporting => Topic started by: cognos05 on 27 Sep 2018 09:03:55 PM

Title: Assign static scores based on member caption
Post by: cognos05 on 27 Sep 2018 09:03:55 PM
Hi Cognos Experts,

I am facing an issue in dimensional reporting where,

I have a set with specific products on it in the rows of a cross tab and in coulmns i am calulating the growth % . Now  I need to have an additional static column to show National average % for each product  in the set .

Example - set(ProdA, ProdB, ProdC)

Crossttab
                   Sales Growth    NationalSalesGrowth(Hardcoded)
ProdA               78%                  23%
ProdB               65%                  35%
ProdC               75%                  56%

I have a calculated expression like this , but I am getting empty values ,even if i have ProdA its not returning 0.23 or 23%

if(caption(currentMember(Products Hierarchy))='ProdA')
Then(0.23)
Else
().


Is there any other way to get the desired result .

I also will have custom  members in product set , where I combine tow products , in that case can I add the data item name in the caption .

Any help is appreciated .

Thanks,