Home All Groups Group Topic Archive Search About

ExecuteNonQuery against a stored procedure does not insert ntext f

Author
2 Feb 2006 3:27 PM
Gavin Sullivan
Hi,

I have an SP that inserts some data including an ntext field for large
strings (4 M chars)

When executed, ExecuteNonQuery returns -1, but the insertion occurs with all
but the ntext field populated correctly, the ntext field is blank. The string
is an xml fragment.

Any ideas?

Regards

Author
2 Feb 2006 3:47 PM
W.G. Ryan - MVP
I'd run profiler and see what's actually being sent back to the server, just
to verify my assumptions were correct. That should shed some insight into
the problem.
Show quote
"Gavin Sullivan" <GavinSulli***@discussions.microsoft.com> wrote in message
news:94118C8E-B42C-4022-A042-545379DA85EE@microsoft.com...
> Hi,
>
> I have an SP that inserts some data including an ntext field for large
> strings (4 M chars)
>
> When executed, ExecuteNonQuery returns -1, but the insertion occurs with
> all
> but the ntext field populated correctly, the ntext field is blank. The
> string
> is an xml fragment.
>
> Any ideas?
>
> Regards
Author
2 Feb 2006 5:32 PM
Gavin Sullivan
Thanx for that.

Solved it in the end, data was being saved, just not displayed in VS!! The
-1 is still a mystery.

Regards

Show quote
"W.G. Ryan - MVP" wrote:

> I'd run profiler and see what's actually being sent back to the server, just
> to verify my assumptions were correct. That should shed some insight into
> the problem.
> "Gavin Sullivan" <GavinSulli***@discussions.microsoft.com> wrote in message
> news:94118C8E-B42C-4022-A042-545379DA85EE@microsoft.com...
> > Hi,
> >
> > I have an SP that inserts some data including an ntext field for large
> > strings (4 M chars)
> >
> > When executed, ExecuteNonQuery returns -1, but the insertion occurs with
> > all
> > but the ntext field populated correctly, the ntext field is blank. The
> > string
> > is an xml fragment.
> >
> > Any ideas?
> >
> > Regards
>
>
>

AddThis Social Bookmark Button