Jul 202010
What is the storage overhead in using VARCHAR in MySQL
Answer:
MySQL allow VARCHAR to have length from a value from 0 to 65,535.
Since MySQL need to store the length of each VARCHAR field, in additional to the actual data itself, it needs 16 bits = 2 bytes for each field. But if the length of VARCHAR during table creation is less than or equal to 255, it only take 1 byte per field.