plsql - maximum storage allocated for date in bytes in oracle -
i have searched found nothing relevant answer question. doubt know max size varchar2 data type 32767 bytes on similar lines how space allocated store value of date data type. treated varchar2 data type? such size depend on number of characters? or different.
thanks
the database stores dates internally numbers. dates stored in fixed-length fields of 7 bytes each, corresponding century, year, month, day, hour, minute, , second.
so date 7 bytes. timestamps longer (11 bytes) hold additional precision, , adding time zone increases further (to 13 bytes). can see if dump
value:
create table t42 (d date, t timestamp); insert t42 (d, t) values (sysdate, systimestamp); column dumpd format a40 column dumpt format a60 select dump(d) dumpd, dump(t) dumpt t42; dumpd dumpt ---------------------------------------- ------------------------------------------------------------ typ=12 len=7: 120,114,3,21,12,30,11 typ=180 len=11: 120,114,3,21,12,30,11,17,32,145,56
Comments
Post a Comment