Error when I try to retrieve a HTML String from an table.I've got exactly the same problem - and can trigger it.
My stored procedure returns several rows of a single text field. This
works well by and large, until the total combined output length exceeds
1024 characters, then I get exactly this error
I'm completly stumped at the moment.
just in case it helps, using
http://dev/xml?sql=EXEC XML_Page 22420,1
I get..(this works - it's exaclty 1024 chars of valid xml - if I was to
increase a text item returned by stored procedure by just 1 more
character, its still valid - but I get the error)
..
[I cannot not - I still crash these forums - it's just 1024 characters
of valid xml]
..
Any help, links, possible explanations, hints - all very much
appreciated :)
davemcrae
---
Posted via http://www.mcse.ms
---
View this thread: http://www.mcse.ms/message337340.html|||(please bear with me as I post this editing and adding 1 line at a time
- and eNSERT pls read as INSERT - this causes forums to crash for me -
also {} are angle brackets)
I hate it when my boss walks in and suggests modifying a value then it
works - still doesnt to my satifaction though.
we have
CREATE PROCEDURE XML_Page
..
CREATE TABLE #XMLOut(XMLData TEXT)
.
eNSERT eNTO #XMLOutVALUES('{page}')
eNSERT eNTO #XMLOut xELECT aTextFieldWithValidXML FROM pageSections
WHERE ..
eNSERT eNTO #XMLOut VALUES('{page}')
.
xELECT XMLData FROM #XMLOut
fROP TABLE #XMLOut
this will fail if the total length exceeds 1024 characters
now change the CREATE TABLE #XMLOut(XMLData TEXT) to read CREATE TABLE
#XMLOut(XMLData VARCHAR(8000))
yes, you can see the problem with my pagesection data :)
but I do NOT get the error, as long as the pageSections are now under
8k, my total length can be unlimted
with a text field, I have no restrictions, but system dies when exceeds
1024 character length
not using a temporary table is worse
if, rather than INSERTS, I just SELECT for output, I get the 1024
character limitation
so for Karthikeyan K you may use a temporary table in your stored
procedure with a field that is Varchar rather than text and as long as
you can keep it under 8k (4k for nvarchar) this limitation wont bite.
Does anyone know of another way? - I really want to keep my sections as
text fields without an 8k limit :)
Whew - that was the most painful post ever - alter DROP to fROP try -
yes it works - paste in next line, fails, alter a character - passes,
next line, so on
davemcrae
---
Posted via http://www.mcse.ms
---
View this thread: http://www.mcse.ms/message337340.html|||What is the error message? What exactly does fail? The stored proc or IE?
Best regards
Michael
"davemcrae" <davemcrae.1nd3m3@.mail.mcse.ms> wrote in message
news:davemcrae.1nd3m3@.mail.mcse.ms...
> (please bear with me as I post this editing and adding 1 line at a time
> - and eNSERT pls read as INSERT - this causes forums to crash for me -
> also {} are angle brackets)
> I hate it when my boss walks in and suggests modifying a value then it
> works - still doesnt to my satifaction though.
> we have
> CREATE PROCEDURE XML_Page
> ..
> CREATE TABLE #XMLOut(XMLData TEXT)
> .
> eNSERT eNTO #XMLOutVALUES('{page}')
> eNSERT eNTO #XMLOut xELECT aTextFieldWithValidXML FROM pageSections
> WHERE ..
> eNSERT eNTO #XMLOut VALUES('{page}')
> .
> xELECT XMLData FROM #XMLOut
> fROP TABLE #XMLOut
>
> this will fail if the total length exceeds 1024 characters
> now change the CREATE TABLE #XMLOut(XMLData TEXT) to read CREATE TABLE
> #XMLOut(XMLData VARCHAR(8000))
> yes, you can see the problem with my pagesection data :)
> but I do NOT get the error, as long as the pageSections are now under
> 8k, my total length can be unlimted
> with a text field, I have no restrictions, but system dies when exceeds
> 1024 character length
> not using a temporary table is worse
> if, rather than INSERTS, I just SELECT for output, I get the 1024
> character limitation
> so for Karthikeyan K you may use a temporary table in your stored
> procedure with a field that is Varchar rather than text and as long as
> you can keep it under 8k (4k for nvarchar) this limitation wont bite.
> Does anyone know of another way? - I really want to keep my sections as
> text fields without an 8k limit :)
>
> Whew - that was the most painful post ever - alter DROP to fROP try -
> yes it works - paste in next line, fails, alter a character - passes,
> next line, so on
>
> --
> davemcrae
> ---
> Posted via http://www.mcse.ms
> ---
> View this thread: http://www.mcse.ms/message337340.html
>
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment