Thursday, May 5, 2011

Oracle Data Types

NUMBER Datatype Examples
Example Description
NUMBER(4) An integer with a maximum length of four digits
NUMBER(6,2) A number with a maximum precision of six digits; at most two digits behind
the decimal point
NUMBER(7,-3) A multiple of thousand with at most seven digits
NUMBER Identical to NUMBER(38,*)
NUMBER(*,5) Identical to NUMBER(38,5)

Character Datatype Examples
Example Description
VARCHAR2(25) Alphanumeric, variable length, up to 25 characters
CHAR(4) Alphanumeric, fixed length, four characters
CLOB Alphanumeric, larger than the maximum size of the VARCHAR2 datatype

Maximum Datatype Sizes
Datatype Maximum Size
NUMBER 38 digits precision
CHAR 2000
VARCHAR2 4000
CLOB 4GB

No comments:

Post a Comment