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: number vs. number(4)

Re: number vs. number(4)

From: Spencer <spencerp_at_swbell.net>
Date: Tue, 23 Jan 2001 22:18:53 -0600
Message-ID: <bHsb6.7873$hD5.148676@nnrp1.sbc.net>

Just to clarify, the space savings are achieved by constraining the range of values that can be stored. For example, a value of +123 will occupy the same space in a NUMBER as a NUMBER(4).

For a column of datatype NUMBER(precision,scale), the precision and scale constrain the values that can be inserted or updated to the column. For example, try comparing the results of of inserting these values into columns of NUMBER(4) and NUMBER:

+1.22222
+1234
+123456

This topic is covered in the oracle documentation.

"Howard J. Rogers" <howardjr_at_www.com> wrote in message news:3a6e31ed$1_at_news.iprimus.com.au...
> Unqualified number fields are up to 38 digits in length (and hence
> approximately 38 bytes variable), and qualified ones are up to the
 qualifier
> in length. It comes down, in the end, to saving space within the row.
>
> Regards
> HJR
>
> <berj_kacherian_not_at_hotmail.com> wrote in message
> news:94la6b$v4j$1_at_nnrp1.deja.com...
> > While creating a table you may choose to specify the length of a
> > numeric column or you may choose to not specify it.
> >
> > What is the difference between
> >
> > number
> >
> > and
> >
> > number(4)
> >
> > What are the advantages or disadvantages of using one or the other?
> >
> >
> > --
> > Out the Ethernet, past the firewall, through the router, down the
> > T1...nothing but Net
> >
> > In order to email me remove the '_not' from my email address.
> >
> >
> > Sent via Deja.com
> > http://www.deja.com/
>
>
>
Received on Tue Jan 23 2001 - 22:18:53 CST

Original text of this message

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