Varchar

Varchar

A VARCHAR or variable character field is a set of character data of indeterminate length. The term varchar refers to a data type of a field (or column) in a database which can hold letters and numbers. Varchar fields can be of any size up to a limit, which varies by databases: an Oracle 11g database has a limit of 4000 bytes,[1] a MySQL 5.7 database has a limit of 65,535 bytes (for the entire row)[2] and Microsoft SQL Server 2008 has a limit of 8000 bytes (unless varchar(max) is used, which has a maximum storage capacity of 2 gigabytes).[3]

nvarchar is a variation of varchar,[4] and which is more suitable depends on the use case.[clarification needed]

See also


References

  1. "Database Concepts". docs.oracle.com.
  2. edmacauley. "char and varchar (Transact-SQL)". msdn.microsoft.com.

Share this article:

This article uses material from the Wikipedia article Varchar, and is written by contributors. Text is available under a CC BY-SA 4.0 International License; additional terms may apply. Images, videos and audio are available under their respective licenses.