ExecuteXMLReader

G

Guest

I have a Sql2000 Stored Proc. that returns the result in the form of XML. I
am calling this SP in my .NET application(webservice) using ADO.net. Can you
please suggest me if I should be using the ExecuteReader or ExecureXMLreader
method?
Also, what are the advantages of using ExecureXMLreader over ExecuteReader

In my .NET application, I need to populate the xml returned by SQL SP in a
XML document.

Thanks.
Rajiv
 
R

Rick

Let's make sure I understand this correctly...

You have an SP that returns XML.

If you use ExecuteReader you will get back this XML.

If you use ExecuteXMLReader you will get XML wrapped inside XML (from the
SP). Something like this:

<newXML>&lt;XMLfromSPTag&gt;value of tag&lt;/XMLfromSPTag&gt;</newXML>

Which one do you want?

Rick
 
G

Guest

Thanks for the reply Rick...

Actually, I want the first option that you mentioned below.

Regards,
Rajiv
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top