Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Optimizing a SQL command
Message
From
13/09/2013 23:58:29
 
 
To
13/09/2013 18:24:15
General information
Forum:
Microsoft SQL Server
Category:
Other
Environment versions
SQL Server:
SQL Server 2008
Application:
Web
Miscellaneous
Thread ID:
01583170
Message ID:
01583248
Views:
35
>>The max for VARCHAR you can use is 8000. Anything over can only be VARCHAR(max).
>
>Then, this answers the concern that this is what I have to use. As I have record containing much more than that in a log.

If the distribution of length is poisson with only a select few records falling above 8000 you could try splitting such logs into varchar(8000) plus varchar(max) overflow field for those few records to help with your speed problem - perhaps even by adding a flag on need for overflow. Hard to say if one of the arrows from that pouch could help not knowing aforementioned length distribution. Yes, ugly and band aid approach, but sometimes crutches help speed.
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform