A DATA_LENGTH
of 22 is just the largest number of bytes it can take to store the largest possible number (Oracle uses 2 digits per byte). A NULL
DATA_PRECISION
implies the maximum of 38.
You can verify this with DBMS_METADATA
:
SQL> create table sotmp ( a int );
Table created.
SQL> select dbms_metadata.get_ddl('TABLE','SOTMP')
2 from dual;
DBMS_METADATA.GET_DDL('TABLE','SOTMP')
--------------------------------------------------------------------------------
CREATE TABLE "PHIL"."SOTMP"
( "A" NUMBER(*,0)
) SEGMENT CREATION DEFER
SQL>
(The "*" in the above output denotes the maximum precision).
BINARY_INTEGER
is not a data type that can be used in table columns. It can only be used as a PL/SQL variable datatype.