varchar
nounUK /ˈvɑːt͡ʃɑː/ · US /ˈvɑɹt͡ʃɑɹ/
Etymology From the data type name, a shortening of variable character.
1
Computing, Databases, Engineering, Mathematics, Natural sciences, Physical sciences, Sciences A text field of indeterminate length in a database, as opposed to the traditional fixed-length field.
- Be aware that varchars will in general provide slower updates but faster selects. By definition, the amount of storage they use is variable.1999, David K. Rensin, Andrew M. Fedorchek, William C. Amo, Microsoft SQL Server 7 secrets:
- With a varchar, the storage is always the actual number of characters you have stored plus 2 bytes. So a varchar(20) with a 5-character word will take up 7 bytes, with the extra 2 bytes holding a size reference for SQL Server.2008, Eric Johnson, Joshua Jones, A Developer's Guide to Data Modeling for SQL Server: