COGNOiSe.com - The IBM Cognos Community

IBM Cognos 8 Platform => COGNOS 8 => Report Studio => Topic started by: bvk.cognoise on 04 Mar 2011 04:45:23 AM

Title: how to can i convert a value into percentage?
Post by: bvk.cognoise on 04 Mar 2011 04:45:23 AM
in my report i have columns like

eg:

type of income                      YTDNS Amounts Percentage
a                                               12
b                                                11
c                                                8

when i tried to to change this data into percentage using data format my result like this

a            1200%
b            1100%
c             800%

i  also removed decimal palces.and made all data format.but  i didnt get correct output.please help me? :(
Title: Re: how to can i convert a value into percentage?
Post by: PRIT AMRIT on 04 Mar 2011 05:11:49 AM
Don't know what's your requirement though, if you just want to see like 12%, 11%, 8%.. Unlock your report, drag a text item and drop beside your measure cell. Double Click the Text Item and define '%'  ;)

should do?  ;D

Thanks
Prit
Title: Re: how to can i convert a value into percentage?
Post by: bvk.cognoise on 04 Mar 2011 05:57:59 AM


hi Prit,

i did the same thing to satsfy my client. but i want to know why its showing like that.

thanks
krishna
Title: Re: how to can i convert a value into percentage?
Post by: PRIT AMRIT on 04 Mar 2011 06:02:12 AM
Off course it would show like that, if you are just showing a number as percentage, then it would multiply with 100.
Title: Re: how to can i convert a value into percentage?
Post by: blom0344 on 04 Mar 2011 08:23:06 AM
When formatting as percentages look at the scale property setting!!
Title: Re: how to can i convert a value into percentage?
Post by: holografix on 13 Mar 2011 07:30:31 PM
You could add a data item to your query and call it something like "Percentage of Column X" then define it as:

[Query X].[Column X] / 100

You will then be able to apply a Percentage data type to it. Hope that made sense.
Title: Re: how to can i convert a value into percentage?
Post by: jive on 14 Mar 2011 01:28:25 PM
Juast do as Bloom said.... check the scale in format properties.

VALUE of 1 scale 0 = 100%
1 scale -1 = 10%
1 scale -2 = 1% 

It's more easy to do that and have te real value instead of transforming the value to get purcentage.

Regards