Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Re: space usuage of number datatype

Re: space usuage of number datatype

From: Connor McDonald <connor_mcdonald_at_yahoo.com>
Date: Tue, 29 Jun 1999 18:17:26 +0800
Message-ID: <37789D36.3342@yahoo.com>


gongji_at_my-deja.com wrote:
>
> Hello:
> I have one question about space usuage of number datatype
> column. I was told that the database assigns a number datatype as
> fixed space, for example, 21 bytes, nomatter how small digital in
> number column.
> I have lots of table which contains lots of numeric column,
> but each column has very small digits. If Oracle database really
> assigns the numeric column like that, my tables eat huge space.
> I know database can smartly assign space to the varchar
> column, that is if the varchar length is small, it gives a small
> space, if varchar length is big, it gives more. I am just wondering
> whether database also treats number datatype column like that?
> Does someone know this?
> Thank you very much.
>
> Jin
>
> Sent via Deja.com http://www.deja.com/
> Share what you know. Learn what you don't.

Numbers only use the storage they need...up to (not always) 21 bytes.

If you put the number "1" into a column, whether it is NUMBER(20) or NUMBER(3) it will use the same storage...

Check out server concepts manual - storage of numbers is quite efficient.
--



Connor McDonald
"These views mine, no-one elses etc etc" connor_mcdonald_at_yahoo.com

"Some days you're the pigeon, and some days you're the statue." Received on Tue Jun 29 1999 - 05:17:26 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US