I’m working on a new database design and I’m not sure about the best approach for text columns. When I don’t know exactly how much text data will be stored in a field, should I just set everything to nvarchar(MAX) to be safe?
I’m wondering if this choice will cause performance issues or use more storage space than necessary. For example, if I have a user name field that might be 20 characters but I set it as nvarchar(MAX), does SQL Server allocate the full maximum space right away?
What are the pros and cons of using nvarchar(MAX) versus trying to estimate a reasonable fixed size like nvarchar(255) or nvarchar(500)? I want to make sure I’m following good database design practices.