I have an app that will have entries of both varchar(max) and varbinary(max) data types. I was considering putting these both in a separate table, together, even if only one of the two will be used at any given time.
The question is whether storing them together has any impact on performance. Considering that they are stored in the heap, I'm thinking that having them together will not be a problem. However, the varchar(max) column will be probably have the text in row table option set.
I couldn't find any performance testing or profiling while "googling bing," probably too specific a question?
The SQL Server 2008 table looks like this:
Id
ParentId
Version
VersionDate
StringContent - varchar(max)
BinaryContent - varbinary(max)
The app will decide which of the two columns to select for when the data is queried. The string column will much used much more frequently than the binary column - will this have any impact on performance?