<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD><TITLE>Message</TITLE>
<META http-equiv=Content-Type content="text/html; charset=us-ascii">
<META content="MSHTML 6.00.2719.2200" name=GENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=#ffffff>
<DIV><SPAN class=853123615-07042003><FONT color=#0000ff
size=2>Pedro,</FONT></SPAN></DIV>
<DIV><SPAN class=853123615-07042003><FONT color=#0000ff
size=2></FONT></SPAN> </DIV>
<DIV><SPAN class=853123615-07042003><FONT color=#0000ff size=2>Remember, you are
working on a binary computer. Thus decimal numbers must be
approximated as the sum of powers of two. For integer numbers these
approximations are exact representations. For floating point numbers,
these approximations are just that - approximations. None of your floating
point numbers are stored with just one digit to the right of the decimal point,
they are only displayed to you as such.</FONT></SPAN></DIV>
<DIV><SPAN class=853123615-07042003><FONT color=#0000ff
size=2></FONT></SPAN> </DIV>
<DIV><SPAN class=853123615-07042003><FONT color=#0000ff size=2>If you cannot
learn to live with floating point numbers, then convert them to the currency
datatype. The currency datatype will meet many of you computational
needs.</FONT></SPAN></DIV>
<DIV> </DIV>
<DIV> </DIV><!-- Converted from text/rtf format -->
<P><SPAN lang=en-us><B><FONT color=#0000ff>Charles Wortz</FONT></B></SPAN>
<BR><SPAN lang=en-us><FONT color=#0000ff>Software Development
Division</FONT></SPAN> <BR><SPAN lang=en-us><FONT color=#0000ff>Texas Education
Agency</FONT></SPAN> <BR><SPAN lang=en-us><FONT color=#0000ff>1701 N. Congress
Ave</FONT></SPAN> <BR><SPAN lang=en-us><FONT color=#0000ff>Austin, TX
78701-1494</FONT></SPAN> <BR><SPAN lang=en-us><FONT
color=#0000ff>512-463-9493</FONT></SPAN> <BR><SPAN lang=en-us><FONT
color=#0000ff>CWortz@tea.state.tx.us</FONT></SPAN> </P>
<DIV></DIV>
<DIV class=OutlookMessageHeader lang=en-us dir=ltr align=left><FONT face=Tahoma
size=2>-----Original Message-----<BR><B>From:</B> Pedro Janssen
[mailto:pedro@plex.nl] <BR><B>Sent:</B> Monday 2003 Apr 07 10:30<BR><B>To:</B>
AccessD@databaseadvisors.com<BR><B>Subject:</B> [AccessD] roundup - decimal
places<BR><BR></FONT></DIV>
<DIV><FONT face=Arial size=2>Hello Group,</FONT></DIV>
<DIV> </DIV>
<DIV><FONT face=Arial size=2>i have a tableA with 5 fields (field size: single,
decimal places:1)</FONT></DIV>
<DIV><FONT face=Arial size=2>Not all fields have values.</FONT></DIV>
<DIV><FONT face=Arial size=2>I want the difference from al those field, so i
added a field diff.</FONT></DIV>
<DIV><FONT face=Arial size=2>I made an update query with the following
sql:</FONT></DIV>
<DIV> </DIV>
<DIV><FONT face=Arial size=2>UPDATE TableA SET TableA.[diff] =
100-Nz([field1],0)-Nz([[field2],0)- etc. etc.;<BR></FONT></DIV>
<DIV><FONT face=Arial size=2>The result that i get in field diff gives many
records with more then 1 decimal places.</FONT></DIV>
<DIV> </DIV>
<DIV><FONT face=Arial size=2>For example: When i have a record which contains
values like 5,1 and 94,9 (all values are typed in this way and are not
calculated) i get as result 0,11176548</FONT></DIV>
<DIV><FONT face=Arial size=2>or a record that contains values like 20,5 and 20,5
i get as result 59,997854.</FONT></DIV>
<DIV><FONT face=Arial size=2>Some result do have only one decimal
place.</FONT></DIV>
<DIV> </DIV>
<DIV><FONT face=Arial size=2>How is this possible? </FONT></DIV>
<DIV> </DIV>
<DIV><FONT face=Arial size=2>TIA</FONT></DIV>
<DIV> </DIV>
<DIV><FONT face=Arial size=2>Pedro Janssen</FONT></DIV></BODY></HTML>