Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.server -> Re: Storage space needed for a numeric(15)
In article <389AD795.B64F18C9_at_free.fr>,
=?iso-8859-1?Q?Fran=E7ois?= de Rochebrune <fderochebrune_at_free.fr>
wrote:
> Hi,
>
> I am planning to create a table using several numeric values from 0 to
> 10 power 15.
> The table will contain millions of records and I am trying to evaluate
> the disk space needed to store the whole database.
> My question is :
> How much space will a numeric(15) field occupy ?
> Will each value occupy 15 bytes ?
> Or is there a binary conversion applied so the space could be 7
bytes ?
> (10 power 15 is approx. 2 power 52, which could fit in 52 bits - less
> than 7 bytes)
>
> Thanks for the answer here or at FdeRoche_at_aol.com
>
Oracle stores all numbers internally in the rdbms as variable length
scientific notation and there is a space formula in the Concepts manual
which is something like: 1 + ( floor(num_digits/2) + 1 ) + 1 where
this last + 1 is only needed for negative numbers.
--
Mark D. Powell -- The only advice that counts is the advice that
you follow so follow your own advice --
Sent via Deja.com http://www.deja.com/
Before you buy.
Received on Fri Feb 04 2000 - 11:13:52 CST