Subject | RE: [firebird-support] Weird Integer Overflow |
---|---|
Author | Alan McDonald |
Post date | 2003-12-19T00:43:50Z |
> Hi when I execute this sql queryhave you tried using F_FIXEDPOINT on each calculation result?
>
> select (("TotalAmount" * (1-("Discount"*0.01)) * (1-("Discount2"*0.01))
> * (1-("Discount3"*0.01)) - "Less" - "Adjustment")) as "GrandTotal"
> from "invoice"
>
> Iam getting a Interger Overflow error. The result of an integer
> operation cause the most significant bit of the result to carry. But I
> don't have any integer field here ... All of them are Numerics(15,2)
> expcept for the discounts field which are numerics(4,2)
>
Alan