Q
Problem solve Get help with specific problems with your technologies, process and projects.

What is the VARCHAR2 datatype?

May I please have a description of the VARCHAR2 datatype? This datatype is used in our catalogue database and I cannot find an explanation that will provide a clear understanding.

May I please have a description of the VARCHAR2 datatype? This datatype is used in our catalogue database and I cannot find an explanation that will provide a clear understanding.
The VARCHAR2 datatype is used to hold character data, including numbers. This datatype is "variable" in the sense that it will not allocate space for unused characters. For instance, if you define your column as VARCHAR2(30), it can hold up to 30 characters. If you are using a single-byte character set, those 30 characters can require 30 bytes of storage space. If you store a five-letter word in that column, the VARCHAR2 datatype does not require all 30 bytes to be allocated. Rather, it only needs the space to store that five-letter word, or five bytes in a single-byte character set.

A complete description of all datatypes can be found in the Oracle documentation.

Dig Deeper on Oracle database design and architecture

Start the conversation

Send me notifications when other members comment.

Please create a username to comment.

SearchDataManagement

SearchBusinessAnalytics

SearchSAP

SearchSQLServer

TheServerSide.com

SearchDataCenter

SearchContentManagement

SearchHRSoftware

Close