Dear all,
I am using the following syntax in order to read a text field on my database.
set textsize 104857600
EXEC sp_dboption 'crm', 'select into/bulkcopy', 'true'
DECLARE @ptrval binary(16)
SELECT @ptrval = TEXTPTR(txt)
FROM TABLE1 WHERE AUTOID=8
ReadText TABLE1.txt @ptrval 0 0
EXEC sp_dboption 'crm', 'select into/bulkcopy', 'false'
The size of my field is 2110765.
With the above method only 4096 characters are read.
If i write something greater than my field's size then doesn't working.
Only if i declare in the size something less or equal of my field's size is working, like this:
EXEC sp_dboption 'crm', 'select into/bulkcopy', 'true'
DECLARE @ptrval binary(16)
SELECT @ptrval = TEXTPTR(txt)
FROM TABLE1 WHERE AUTOID=8
ReadText TABLE1.txt @ptrval 0 2110765
EXEC sp_dboption 'crm', 'select into/bulkcopy', 'false'
So how can i find the size dynamic and declare it on the READTEXT command and what is the meaning of textsize property?
Many thanks.
I am using the following syntax in order to read a text field on my database.
set textsize 104857600
EXEC sp_dboption 'crm', 'select into/bulkcopy', 'true'
DECLARE @ptrval binary(16)
SELECT @ptrval = TEXTPTR(txt)
FROM TABLE1 WHERE AUTOID=8
ReadText TABLE1.txt @ptrval 0 0
EXEC sp_dboption 'crm', 'select into/bulkcopy', 'false'
The size of my field is 2110765.
With the above method only 4096 characters are read.
If i write something greater than my field's size then doesn't working.
Only if i declare in the size something less or equal of my field's size is working, like this:
EXEC sp_dboption 'crm', 'select into/bulkcopy', 'true'
DECLARE @ptrval binary(16)
SELECT @ptrval = TEXTPTR(txt)
FROM TABLE1 WHERE AUTOID=8
ReadText TABLE1.txt @ptrval 0 2110765
EXEC sp_dboption 'crm', 'select into/bulkcopy', 'false'
So how can i find the size dynamic and declare it on the READTEXT command and what is the meaning of textsize property?
Many thanks.