I made a decision based on a discussion with other colleagues: I partitioned SOME LOB data (also SomeID and Date columns) into partitioned data in another table.
Most importantly: I skipped to consider the speed of updating columns , and how often data is queried frequently , and when they become old enough not to be interesting in the vast majority (but not all).
And that is what makes the difference in this case.
So, I came up with:
MyTable ( SomeID varchar(20)-- queried most often / Updated never Date DateTime -- queried most often / Updated never Status VarChar(10) -- queried most often / Updated few times after insert Title VarChar(50) -- queried most often / Updated never -- some more columns here SomeSmallXML xml -- queried quite often / Updated few times after insert SomeOtherSmallXML xml -- queried quite often / Updated never MyData varbinary(max) -- queried rarely / Updated never MyOtherData varbinary(max) -- queried rarely / Updated 1 shortly after insert )
So, as you can see, some data LOB-MyData and MyOtherData varbinary (max) become static after a short time. They are large enough, so I would like to store them on a chip disk and at some point put them on a read-only partition. Since a later date, since more often I need "MyData" or "MyOtherData".
So, the final design looks something like this:
MyTable ( SomeID varchar(20) Date DateTime Status VarChar(10) Title VarChar(50) -- some more columns here SomeSmallXML xml SomeOtherSmallXML xml ) MyTableLOB ( SomeID varchar(20) Date DateTime -- used for partitioning MyData varbinary(max) MyOtherData varbinary(max) )
Jānis source share