473,394 Members | 1,852 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,394 software developers and data experts.

Decimals in Access Report

I have a problem with the decimals in a report I created in Access Database. In a table I have two fields. One is the "price" the second one is "quantity". When I develop a report I would like to have another field which is a result of Price * Quantity with a 2 decimals on the result. Example: 914,539.00 * $50.21, the result must be $45,919,003.19, however the report will shows always a wrong result of $45,919,002.35. I already tried to change the format in both places (table and report) but the wrong result is always showing up.

Could you please try to help me on this? I would very much appreciate.

Thanks

Mario Pais
Jun 11 '07 #1
3 1577
MMcCarthy
14,534 Expert Mod 8TB
I am moving this question to the Access forum.

ADMIN
Jun 11 '07 #2
MMcCarthy
14,534 Expert Mod 8TB
Try this ...

Set quantity to Long Integer. Set Price to Currency

Now set new field to

Format(Price * Quantity, "Currency")
Jun 11 '07 #3
MSeda
159 Expert 100+
Is it possible that the price contains some digits beyond the second place. Even thought the data type in the table is set to currency you can still save data with more than two decimal places it just shows only two. This could happen if the price was calculated by multiplying by a markup or dividing a pallette price to get the each and not rounding the product before saving it to the table.
You may be seeing 50.21 but are actually multiplying by 50.20999908.
Jun 11 '07 #4

Sign in to post your reply or Sign up for a free account.

Similar topics

3
by: Nicola | last post by:
Hi Everyone, I am new to programming and would like to know how to open an access Report from within vb 6. I am trying to write a program to organise cross stitch threads. I have found out how...
2
by: eskil | last post by:
Hi, I am running a pivot table based on a query. I need to be able to display decimal precision for on a calculated field (in the query). The query returns the values correctly (i.e. with the...
3
by: munkis29 | last post by:
Hey all, Hopefully someone here can help me, I've got a problem and not sure how to aproach it. I'm using Access 2003 and have a table with one field: FileID in it there are many values, many of...
1
by: roger2282 | last post by:
help, I am trying to update a field on my database and cant seem to get the right value stored eg on reading the database field i get the values I need such as 31.24, 3.15 and 16.00 and I...
1
by: Capn Stoobie | last post by:
I have a database that I regularly import data into from a text file. The text file is produced by payroll software, and it is always the same format. Most of the time my acImportDelim command...
4
by: Jaash | last post by:
I have a graph within a report (simply built with the Chart Wizard). However when my source data set falls to a lower set of numbers ... the Y-Axis will display 0, 0.5, 1, 1.5, etc. Is there a...
13
by: vsts2007 | last post by:
hi, how can I change the number of decimals appeared in access reports... I put a formula in query and its giving three to four decimals in the output of report. I want to change the number of...
12
by: CNiall | last post by:
I am very new to Python (I started learning it just yesterday), but I have encountered a problem. I want to make a simple script that calculates the n-th root of a given number (e.g. 4th root of...
8
by: =?Utf-8?B?a2FyaW0=?= | last post by:
Hello All, why is this code is not showing the result in this format: 0.00 and showing it as only 0 Private Sub btn1_Click Debug.Print(Format$(Rnd() * 100, "0.00")) Dim d As Double =...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
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
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
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

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.