August 31, 2005 at 4:36 pm
I have a rather large insert statement coming from VB. One of the fields it inserts is a TEXT field. When going over the 8000 character limit, it truncates it. I was under the impression that data would not be truncated when using the TEXT field.
I've tried the writetext and all stored procedures, but they don't work because in the body of text there are a lot of '+' characters because I'm concatenating strings.
Is there anything I can do so the data will not be truncated on an INSERT statement? I'm very frustrated as I've been working on this for awhile and I'm not sure why it's still truncating to 8000 characters.
Thanks,
Drew
August 31, 2005 at 4:53 pm
Do you have to generate the SQL statement? You can create an SP with a parameter of type TEXT - then insert the value of that parameter (along with the other values of the table which you would also pass as parameters).
Alternatively, look up books online about the commands to work with text fields. Rather than attempting to insert more than 8000 chars at once, you can use the commands to put in 8000 chars, then another 8000 chars, etc, etc - you could still use your SQL script - just slightly modified.
Cheers,
Ian
September 1, 2005 at 1:51 am
You need to use the ADODB AppendChunk method. I believe that you cannot pass parameters longer than 8060 bytes.
Viewing 3 posts - 1 through 2 (of 2 total)
You must be logged in to reply to this topic. Login to reply