Answer the question
In order to leave comments, you need to log in
Does it make sense to store a byte in a varchar(max) field in this case?
I have a table with fields
Answer the question
In order to leave comments, you need to log in
varchar(max) blob type. In SQLServer, it is stored in a separate location from the main record and is not included in the 8kb per record limit. From memory it takes 2 bytes + the size of the stored value. It is better, by the way, to store in nvarchar, since after all it is already the age of Unicode.
If you have data up to 4000 characters, it's better to store it in nvarchar(4000) - the data is stored along with the key.
As long as you do not have millions of records and there are no strict limits on the size of the database, do not complicate and store in a way that is convenient for programmatic processing.
How is memory reserved in a varchar(max) field?
- varchar Reserves nothing - takes up as much space as needed to store data
reserves another data type - char
Actually, this is one of the main differences between these data types
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question