469,636 Members | 1,544 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,636 developers. It's quick & easy.

How to get Multiple Recordsets from StoredProc?

I prefer to use stored procedures over having sql statements sitting in my
..NET code.

My problem is I can not figure out how get .NET to understand there are
multiple recordsets coming back. Each of the recordsets is returning xml
data and if called individually would be called as :

Dim myCmd as SqlCommand=New SqlCommand("ae_RegGetShow",myCnct)
myDataSet.ReadXml(myCmd.ExecuteXmlReader(), XmlReadMode.Fragment)

The stored procedure has something like the following

selet * from table1 as show for xml auto,xmldata
select * from table2 as options for xml,xmldata

Any thoughts or suggest?

Cheers
Keith
Nov 12 '05 #1
2 2096
How is this question related to xml???
"Keith Chadwick" <kc*******@leewardsystems.com> wrote in message
news:O8****************@tk2msftngp13.phx.gbl...
I prefer to use stored procedures over having sql statements sitting in my
.NET code.

My problem is I can not figure out how get .NET to understand there are
multiple recordsets coming back. Each of the recordsets is returning xml
data and if called individually would be called as :

Dim myCmd as SqlCommand=New SqlCommand("ae_RegGetShow",myCnct)
myDataSet.ReadXml(myCmd.ExecuteXmlReader(), XmlReadMode.Fragment)

The stored procedure has something like the following

selet * from table1 as show for xml auto,xmldata
select * from table2 as options for xml,xmldata

Any thoughts or suggest?

Cheers
Keith

Nov 12 '05 #2
Because I am using the ExecuteXMLReader and ReadXml on the dataset object.
Also the sql statements in the sp are for xml auto,XMLDATA.

Keith

"Dimitre Novatchev" <dn********@yahoo.com> wrote in message
news:bq*************@ID-152440.news.uni-berlin.de...
How is this question related to xml???
"Keith Chadwick" <kc*******@leewardsystems.com> wrote in message
news:O8****************@tk2msftngp13.phx.gbl...
I prefer to use stored procedures over having sql statements sitting in my .NET code.

My problem is I can not figure out how get .NET to understand there are
multiple recordsets coming back. Each of the recordsets is returning xml data and if called individually would be called as :

Dim myCmd as SqlCommand=New SqlCommand("ae_RegGetShow",myCnct)
myDataSet.ReadXml(myCmd.ExecuteXmlReader(), XmlReadMode.Fragment)

The stored procedure has something like the following

selet * from table1 as show for xml auto,xmldata
select * from table2 as options for xml,xmldata

Any thoughts or suggest?

Cheers
Keith


Nov 12 '05 #3

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

8 posts views Thread by Tull Clancey | last post: by
16 posts views Thread by Randy Harris | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.