If you are unable to create a new account, please email support@bspsoftware.com

 

News:

MetaManager - Administrative Tools for IBM Cognos
Pricing starting at $2,100
Download Now    Learn More

Main Menu

Decimal point - additon issue

Started by cognosun, 12 Nov 2012 02:46:55 AM

Previous topic - Next topic

cognosun

Hi Gurus,

I have decimal values like :

1.4678
4.7789
---------
6.2467  ( total)

In the report we are displaying only one value after decimal point ( i.e. 1.4, 4.7), using data format option.

But when we add these values, instead of showing total of 1.4 + 4.7 = 6.1, it's still showing above original total i.e.(6.2, which it's picking from 6.2467)

What it's doing is correct...but is there any way to tell cognos , not to use original total, instead add values after formatting is done.

Many Thanks.

blom0344

You will actively need to round figures to the right precision and then perform the addition against those rounded figures. Cognos has standard functions for this!!

cognosun

Can you tell me more about Right precision...

blom0344

Well, you want a certain number of values after the decimal point, don't you?  Check the Cognos _round function. It is well documented within Report Studio..

cognosun

Everything is in place..except totals are not related to displayed values.

I've observed this thing in Cognos sample packages as well...there if you observer 'Revenue' fact column is in decimal and if you add those values manually you get wrong values ( logically it's correct, because it's adding original values, but as per my requirements it's wrong).

Also...round function will roundup values, here we don't need any roundup (floor or celing), we need a plane addition.


blom0344

 ::)  In your original post you wanted to add a list of rounded figures instead of adding figures that where merely formatted but internally still with highest precision.

If you totalize the ROUNDED figures you should get the desired result

I'm getting a bit exasperated here, but could also simply miss where you are after   ???

cognosun

let me post it as a new topic...as simple as possible.