Comparison of the VARCHAR(max) and VARCHAR(n) SQL Server Data Types
'Problem
You are developing a SQL Server application and at some point in your code you receive the error "String or binary data would be truncated". After digging into the code you discovered that this error message is caused because a table has a VARCHAR(1000) column and you need to insert more than 1000 characters. Someone on your team suggest using the VARCHAR(max) data type, but you are unsure about the implications of the this data type. Read this tip to learn what you should know about the SQL Server VARCHAR(Max) vs. VARCHAR(n) data types.
Solution
In order to decide between using VARCHAR(Max) or VARCHAR(n) we have to understand that even when both data types look the same, they have some major differences pertaining to storage, behavior and of course their intended usage.'...
Trackbacks
Die Kommentarfunktion wurde vom Besitzer dieses Blogs in diesem Eintrag deaktiviert.
Kommentare
Ansicht der Kommentare: Linear | Verschachtelt