<div dir="ltr"><div class="gmail_quote"><div class="gmail_quote">On Thu, Mar 8, 2012 at 3:28 AM, Marcos Douglas <span dir="ltr"><<a href="mailto:md@delfire.net">md@delfire.net</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Integer math... what did you mean?</blockquote><div><br>Integer math =  Currency or in  DB numeric(18, 4) <br><br>in Firebird <br>create domain AMOUNT as numeric(18,4);<br></div></div><br>On Thu, Mar 8, 2012 at 12:43 AM, Graeme Geldenhuys <span dir="ltr"><<a href="mailto:graemeg.lists@gmail.com">graemeg.lists@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div id=":13c">This is why our accounting app uses Integer math (and when stored in the database). Only when amounts are displayed to the user, do we convert the integer value to currency. This greatly reduced our calculation and rounding problems.<span class="HOEnZb"><font color="#888888"><br>

</font></span></div></blockquote></div><br>Yes i do that from more than 10 years, Float/Extended have problem when rounding it and sum that rounding, it is only good in Science not Accounting.<br><br>Currency for me is  Int64 (* int of 10000 or binary shifted) it is more stable and not lose any cent when sum the balances, until i passed it to ABS, ABS convert it to float and return back to Currency, that my problem here.<br>
<br>In the future i like to have new kind of Currency (integer) but more extend (* 1000000 for example).<br clear="all"><br><div dir="ltr">Best Regards<br>Zaher Dirkey</div><br>
</div>