How to round off numbers

  • Thread starter Thread starter Austin Myers
  • Start date Start date
A

Austin Myers

Complete newbie using Access 2003 on Windows XP Pro.

I'm putting together a small data base application and have ran into what I
thought was a simple problem and it's turned out to be anything but simple.

In one form I take the quantity of a product, multiply it by the unit cost
for the total. I limit the number of decimal places to 2. This forces it
to round off to the nearest penny. So far so good.

The problem is that when I add the totals together for a grand total, they
don't come out right and can be off a penny in either direction. I suspect
this is because Access is adding the real totals (non-rounded) instead of
the displayed totals.

This obviously causes a problem when customers add up the totals for
themselves and its wrong. How do I force Access to add the displayed totals
(rounded) instead of the non-round real totals that may be several decimal
places in length?

Thanks
 
Are you using the Cuurency Type for your extended amount (Price*Qty)?
Problem should go away you you do.
another option would be to make your sum field, which I guess reads
=Sum({PxQ]) at the moment
to
=Sum(Round([PxQ]),2)
 
Back
Top