TRUNC function Error

asjex

New Member
Joined
May 23, 2012
Messages
3
He're's my data:

98.9000000000 (location Register!N1006)

I'm using this formula:

=TRUNC(Register!N1006, 2)

This should truncate the number to 98.90, but I get 98.89. What gives?

Screen grab - if this works
edit


I'm using Excel 2010 on Windows XP.
 

Excel Facts

Pivot Table Drill Down
Double-click any number in a pivot table to create a new report showing all detail rows that make up that number
He're's my data:

98.9000000000 (location Register!N1006)

Hi
Welcome to the board

Do you mean that you've confirmed that that's the data or that's just what you are seeing?

Please confirm. In another cell write:

=(Register!N1006=98.9)

and check if the result of the formula is TRUE.
 
Upvote 0
Thank you for your help!

The formula was FALSE. I brought it out to 10 decimals, and apparently that wasn't enough - I had to go to 13 to see that the number was actually

98.899999999999700000000000000000

So, follow up question, then.

I have a formula
=O105+N104

O105 is
-480.000000000000000000000000000000
and N104 is
541.900000000000000000000000000000
yet it equals
61.899999999999700000000000000000


????????????????????????????????????

- Aaron
 
Last edited:
Upvote 0
The "set precision as displayed" is magic for me, thanks!

Otherwise, I'll have to use ROUND on ALL my calculations!

Thanks for pointing me to the KB article. Perfect.

Thanks again!

- Aaron
 
Upvote 0
I'm glad it helped.

Remark: "Set precision as displayed" is very handy in some cases but be sure you understand that all that is not displayed is really lost, there's no going back.

Notice ms warning:

Note Using the Precision as displayed option can have cumulative calculation effects that can make your data increasingly inaccurate over time. Use this option only if you are certain that the displayed precision will maintain the accuracy of your data.

http://office.microsoft.com/en-us/excel-help/set-rounding-precision-HA010218870.aspx
 
Upvote 0

Forum statistics

Threads
1,214,983
Messages
6,122,582
Members
449,089
Latest member
Motoracer88

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top