COGNOiSe.com - The IBM Cognos Community

IBM Cognos 8 Platform => COGNOS 8 => Report Studio => Topic started by: RamLal on 26 Jun 2008 11:16:42 AM

Title: Calculated column
Post by: RamLal on 26 Jun 2008 11:16:42 AM
there is a column called "customer", It has four letter data in it for ex: "ABCD". I am trying to create a Calculated column , which will have all the data starts with "A" from customer column and only display last two letters ( in this case : "cd") in that column.
your response is highly appreciable.

Thanks.
Title: Re: Calculated column
Post by: blom0344 on 26 Jun 2008 01:22:22 PM

CASE WHEN
[Customer] like 'A%'
then (substring([Customer,3,2))
else (null)


As definition of the calculated data-item..