COGNOiSe.com - The IBM Cognos Community

IBM Cognos 10 Platform => Cognos 10 BI => Report Studio => Topic started by: zgeorge on 27 Feb 2018 01:49:27 PM

Title: IF AND Statement
Post by: zgeorge on 27 Feb 2018 01:49:27 PM
I have a crosstab that utilizes drill-down capabilities and have created a report expression that changes the text label based on a condition. What I need to do is implement an 'AND' statement to check to left most columns header text. My report condition is as follows:
The left most column([Total(Set = EBR Rollup1)] is a total of all columns after it.

if([Crosstab Query2].[Set - EBR Rollup1] = 'Test') AND ([Crosstab Query2].[Total(Set - EBR Rollup1)] = 'Test2')
then ('Test**')
else ([Crosstab Query2].[Set - EBR Rollup1])

So after the drill-down, I need the report expression to change the header text 'Test' to 'Text**' only if the total column says 'Test2'.