Page 1 of 1

Nearest 100 million in report studio

Posted: Tue Jul 27, 2010 11:56 pm
by daya007
Hi,
I have a dynamic calculation which results x,xxx,xxx,xxx,xxx.xx number. Client dont want to c that number, he wants to c the calculation rounding to nearest 100 million. For example if the calculation yields 502,173,318,202.96, he wants the number to be shown as 502,200,318,202.96. if calculation is 502,143,318,202.96, he wants the num to be shown as 502,100,318,202.96.
I am not able to do this. I am new to cognos. Please help. If u need more clarity on question reply to this thread.

Thanks
Daya

Re: Nearest 100 million in report studio

Posted: Wed Jul 28, 2010 12:51 am
by kpk
daya007 wrote:Hi,
I have a dynamic calculation which results x,xxx,xxx,xxx,xxx.xx number. Client dont want to c that number, he wants to c the calculation rounding to nearest 100 million. For example if the calculation yields 502,173,318,202.96, he wants the number to be shown as 502,200,318,202.96. if calculation is 502,143,318,202.96, he wants the num to be shown as 502,100,318,202.96.
I am not able to do this. I am new to cognos. Please help. If u need more clarity on question reply to this thread.

Thanks
Daya
Hi,

Are you sure that it is the real requirement?

Maybe the client would like to see
502,200,000,000.00 instead of 502,173,318,202.96 and
502,100,000,000.00 instead of 502,143,318,202.96.

You can use the ROUNDP function to solve it.

If the requirement is the one I suppose then the function should look like:
['B']=ROUNDP(['A']/100000000,0)*100000000

If the requirements is the one you asked for in the post then the rule is the following:
['B']=ROUNDP(['A']/100000000,0)*100000000+['A']-ROUNDP(['A']/1000000,0)*1000000

Kind regards,
Peter

Re: Nearest 100 million in report studio

Posted: Wed Jul 28, 2010 12:57 am
by kpk
An additional thought:
Make sample calculation with your requirements in Excel. If it works in Excel then it is very easy to replace the Excel functions with TM1 own functions.

Re: Nearest 100 million in report studio

Posted: Wed Jul 28, 2010 1:05 am
by daya007
thanks for the reply. I was mistaken, the way u said is right. Ill try to solve with ur solution.

Re: Nearest 100 million in report studio

Posted: Wed Jul 28, 2010 1:18 am
by daya007
actually cube was integrated to cognos 8. I have to do it at report studio level. how can i do it at report studio level.