Apologies for the rather basic question.
I have an error string that is built dynamically. The data in the string is passed by various third parties so I don't have any control, nor do I know the ultimate size of the string.
I have a transaction table that currently logs details and I want to include the string so that I can reference back to it if necessary.
2 questions:
- How should I store it in the database?
- Should I do anything else such as contrain the string in code?
I'm using Sql Server 2008 Web.
nvarchar(max)msdn.microsoft.com/en-us/library/ms186939(v=sql.100).aspx, if its bigger than that you are logging too much error information.