Author |
Topic  |
|
D3mon
Senior Member
   
United Kingdom
1685 Posts |
|
DavidRhodes
Senior Member
   
United Kingdom
1222 Posts |
Posted - 09 August 2004 : 12:30:18
|
It's the size of the row that is limited to 8kb. So you could have a table with 1 varchar(8000) column or 8 varchar(1000) columns. |
The UK MkIVs Forum |
 |
|
D3mon
Senior Member
   
United Kingdom
1685 Posts |
Posted - 09 August 2004 : 12:33:12
|
Ah that makes sense. Decided to use a 'text' field, and discovered thatstored procedures have problems with long text fields. Dropped the SP and used a standard Text Query - works a treat now! |
 Snitz 'Speedball' : Site Integration Mod : Friendly Registration Mod "In war, the victorious strategist only seeks battle after the victory has been won" |
 |
|
redbrad0
Advanced Member
    
USA
3725 Posts |
|
Jeepaholic
Average Member
  
USA
697 Posts |
Posted - 10 August 2004 : 01:54:13
|
What problems do stored procedures have with long text fields? I've never run into any issues myself... Other than the fact that MS SQL isn't optimized to search through them very well. |
Al Bsharah Aholics.com
Jeepaholics Anonymous Broncoholics Anonymous Network Insight
|
Edited by - Jeepaholic on 10 August 2004 01:54:44 |
 |
|
D3mon
Senior Member
   
United Kingdom
1685 Posts |
|
pdrg
Support Moderator
    
United Kingdom
2897 Posts |
Posted - 10 August 2004 : 06:53:38
|
Nvarchar is unicode varchar with each screen character represented by 2 'programatic' characters, hence max is Nvarchar(4000) [4000 * 2 chars = 8k]
Re the syntax error, were you then trying to stuff 10k characters into a varchar (8000) datatype or something? that would truncate, and so leave the data in a confused condition |
 |
|
DavidRhodes
Senior Member
   
United Kingdom
1222 Posts |
Posted - 10 August 2004 : 09:48:24
|
quote: Originally posted by Jeepaholic
What problems do stored procedures have with long text fields? I've never run into any issues myself... Other than the fact that MS SQL isn't optimized to search through them very well.
I use text and ntext with in stored procedures with no problems, I think the only thing you cannot do is set them as OUTPUT parameters, but I may be wrong.
Text, ntext, blob fields do not count as part of the 8Kb limit as they are stored seperately. |
The UK MkIVs Forum |
 |
|
pdrg
Support Moderator
    
United Kingdom
2897 Posts |
Posted - 10 August 2004 : 10:16:26
|
strictly speaking, they do count towards the 8k limit, but only a few bytes as a pointer towards the appropriate page |
 |
|
|
Topic  |
|