Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.misc -> Re: Oracle internal NUMBER type
Jaroslaw Gramacki wrote:
> On Tue, 5 Nov 2002 12:09:34 +0300, "Vladimir M. Zakharychev"
> <bob_at_dpsp-yes.com> wrote:
>
>
>>Different processors implement floating-point arithmetic differently. >>Besides, Oracle may be ran on a platform with no FPU unit whatsoever. >>At the same time, Oracle guarantees portability of values with precision >>up to 38 decimal digits across all supported platforms. No wonder they >>implemented floating-point math that way... >>
PL/SQL is well optimised for database access but not for number crunching, although native compilation partially addresses this. There are a variety of ways you can proceed; you can write a Pro*C or OCI program, or use a Java Stored Procedure as Java is better suited to number crunching than PL/SQL, or use external procedures to perform the maths.
There are a variety of high precision libraries available for C that will be able to handle the precision within Oracle. The basic data types are not sufficient (and it's not just the FP stuff - an int can't hold a NUMBER, although a 128 bit data type, if you've got one, can hold 10^38.)
Dave.
-- Email address munged to avoid SPAM Reverse the last two parts to reply directlyReceived on Tue Nov 05 2002 - 05:35:48 CST
![]() |
![]() |