473,395 Members | 1,454 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,395 software developers and data experts.

Reports Rounding Error

Hello,

I've inherited a tax report where all of the financial numbers are
currency.This is a detailed report that lists amount, tax and total for
that day ( total is listed in the database). The report gets its
information from a query. At this point all is working

Then in the report footer I am trying to total the entire amount for
that particular day. The basic formula in use is:
=Sum([TOTAL])
This works the majority of time, but on some days we will be shy a
penny or 2.

I have tried many different calculations (* 100/100, Rounding, CCur,
etc) but nothing seems to work.

I'm using ms access 2003 sp2

Any ideas would be MUCH appreciated

Dec 14 '06 #1
3 2257
Is the TOTAL Field in the database defined as Currency? Currency is supposed
to carry 4 decimal places, to avoid rounding errors. If you have set
"Currency" as the Format for the Control on the Report, that alone would not
prevent rounding errors.

Larry Linson
Microsoft Access MVP

<ga*******@yahoo.comwrote in message
news:11**********************@73g2000cwn.googlegro ups.com...
Hello,

I've inherited a tax report where all of the financial numbers are
currency.This is a detailed report that lists amount, tax and total for
that day ( total is listed in the database). The report gets its
information from a query. At this point all is working

Then in the report footer I am trying to total the entire amount for
that particular day. The basic formula in use is:
=Sum([TOTAL])
This works the majority of time, but on some days we will be shy a
penny or 2.

I have tried many different calculations (* 100/100, Rounding, CCur,
etc) but nothing seems to work.

I'm using ms access 2003 sp2

Any ideas would be MUCH appreciated

Dec 14 '06 #2
Yes TOTAL is defined as Currency.

I have tried setting all of the fields to various types and none seem
to work.

Thank you,
Carrie
Larry Linson wrote:
Is the TOTAL Field in the database defined as Currency? Currency is supposed
to carry 4 decimal places, to avoid rounding errors. If you have set
"Currency" as the Format for the Control on the Report, that alone would not
prevent rounding errors.

Larry Linson
Microsoft Access MVP

<ga*******@yahoo.comwrote in message
news:11**********************@73g2000cwn.googlegro ups.com...
Hello,

I've inherited a tax report where all of the financial numbers are
currency.This is a detailed report that lists amount, tax and total for
that day ( total is listed in the database). The report gets its
information from a query. At this point all is working

Then in the report footer I am trying to total the entire amount for
that particular day. The basic formula in use is:
=Sum([TOTAL])
This works the majority of time, but on some days we will be shy a
penny or 2.

I have tried many different calculations (* 100/100, Rounding, CCur,
etc) but nothing seems to work.

I'm using ms access 2003 sp2

Any ideas would be MUCH appreciated
Dec 14 '06 #3
as a follow-up,

Some of the calculations have been variations of:

CCur(CLng(Sum([TOTAL]))*100)/100)

=Sum(([TOTAL])*100+0.5)/100

Thank you

gabo22...@yahoo.com wrote:
Yes TOTAL is defined as Currency.

I have tried setting all of the fields to various types and none seem
to work.

Thank you,
Carrie
Larry Linson wrote:
Is the TOTAL Field in the database defined as Currency? Currency is supposed
to carry 4 decimal places, to avoid rounding errors. If you have set
"Currency" as the Format for the Control on the Report, that alone would not
prevent rounding errors.

Larry Linson
Microsoft Access MVP

<ga*******@yahoo.comwrote in message
news:11**********************@73g2000cwn.googlegro ups.com...
Hello,
>
I've inherited a tax report where all of the financial numbers are
currency.This is a detailed report that lists amount, tax and total for
that day ( total is listed in the database). The report gets its
information from a query. At this point all is working
>
Then in the report footer I am trying to total the entire amount for
that particular day. The basic formula in use is:
=Sum([TOTAL])
This works the majority of time, but on some days we will be shy a
penny or 2.
>
I have tried many different calculations (* 100/100, Rounding, CCur,
etc) but nothing seems to work.
>
I'm using ms access 2003 sp2
>
Any ideas would be MUCH appreciated
>
Dec 15 '06 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

20
by: Raoul Watson | last post by:
By any chance, anyone got a rounding routine that does a work around the VB "round" bug? I still find it amazing that a company as large as Microsoft would put out a math package that is so...
12
by: 6tc1 | last post by:
Hi all, I just discovered a rounding error that occurs in C#. I'm sure this is an old issue, but it is new to me and resulted in a fair amount of time trying to track down the issue. Basically...
10
by: Mike S | last post by:
Does anyone know the logic behind why in VB.NET the result of a floating-point division ('/') is -rounded- on being converted to an integer type, such as with statements like Dim x As Integer =...
13
by: Shirsoft | last post by:
I have a 32 bit intel and 64 bit AMD machine. There is a rounding error in the 8th digit. Unfortunately because of the algorithm we use, the errors percolate into higher digits. C++ code is...
6
by: abcd | last post by:
I am trying to write a rounding function. Rounding to 0.05. e.g. I should get below results 6.125 --6.15 1.699 --1.7 1.1985 --1.20 0.5625 --0.60 Can someone have any sample for...
5
by: Spoon | last post by:
Hello everyone, I don't understand how the lrint() function works. long lrint(double x); The function returns the nearest long integer to x, consistent with the current rounding mode. It...
206
by: md | last post by:
Hi Does any body know, how to round a double value with a specific number of digits after the decimal points? A function like this: RoundMyDouble (double &value, short numberOfPrecisions) ...
30
by: bdsatish | last post by:
The built-in function round( ) will always "round up", that is 1.5 is rounded to 2.0 and 2.5 is rounded to 3.0. If I want to round to the nearest even, that is my_round(1.5) = 2 # As...
2
Pittaman
by: Pittaman | last post by:
Hello I am creating some crystal reports (for visual studio 2005) based on the content of certain .NET objects. I'm doing this in .NET 2.0. For one of them I'm using a Cross-table to summarize...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.