By: Borland Staff
Abstract: The best way to round a double precision number is to write a UDF to do the rounding
Can't round a double precision number to a whole number
The information in this article applies to:
* InterBase v4.x
* InterBase v5.x
The best way to round a double precision number is to write
a UDF to do the rounding. InterBase does not have any internal
An alternative would be to cast the double to an integer. This
will work as long as the result will fit in the 32-bit integer
field. This is not the favorable method, however, because the 64-bit
double precision fields can hold significantly larger numbers than
the integer field can. If the rounded number does NOT fit into a 32-bit
integer, an arithmetic overflow error will be produced.
Could not retrieve comments. Please try again later.
Free Developer Edition!
Click here to download a free non-expiring Developer Edition or 30-day trial >
More InterBase Info
InterBase XE3 Product Info
Free Developer Edition download
InterBase on Google+
Follow @InterBase on Twitter
Server Response from: ETNASC04