Thursday, June 23, 2011

Why varchar2?

One reason why you don't name your keywords with size limitations.

varchar2 is an Oracle datatype, equivalent to its (as well as TSQL's) own varchar.


The differentiation between Oracle's varchar and varchar2 seems to have originated back whenthe ANSI SQL standard was still being formulated. I cannot locate any definitive references as to what exactly the implementation differences, if any, were initially (pre-Oracle 7), as this remains a source of confusion. Suffices to say that the two are practically treated as synonyms since Oracle 7. Both suffered improvements (maximum size went from 2k to 4k) in release 8. Note that TSQL's varchar can store 8k

No comments: