Subject RE: [firebird-support] Mathematics problem
Author Rick Debay
How are PC and RABAT_PROC defined?

-----Original Message-----
From: firebird-support@yahoogroups.com
[mailto:firebird-support@yahoogroups.com] On Behalf Of miki_avramovic
Sent: Friday, October 07, 2005 1:36 PM
To: firebird-support@yahoogroups.com
Subject: [firebird-support] Mathematics problem

I founded a little problem with evaluation of this formula in procedure
or trigger:

PC = 109.87
RABAT_PROC = 5


1. case:
PCR = PC - RABAT_PROC * PC / 100; Result for PCR is 104.291 (OK)

2. case:
PCR = PC - RABAT_PROC * (PC / 100); Result for PCR is 109.33 (Bad)

3. case:
PCR = PC - (RABAT_PROC * PC) / 100; Result for PCR is 109.33 too
(Bad)

My version of Firebird server is 1.52. I try with both of classical and
super server.


With Best Regards
Miki Avramovic







------------------------ Yahoo! Groups Sponsor --------------------~-->
Get Bzzzy! (real tools to help you find a job). Welcome to the Sweet
Life.
http://us.click.yahoo.com/A77XvD/vlQLAA/TtwFAA/67folB/TM
--------------------------------------------------------------------~->

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Visit http://firebird.sourceforge.net and click the Resources item on
the main (top) menu. Try Knowledgebase and FAQ links !

Also search the knowledgebases at http://www.ibphoenix.com

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Yahoo! Groups Links