Multiple recordset from a stored procedure

J

Jon Spivey

Hi,
using vb.net/sql server 2000 migrating an app from asp to asp.net. I have a
stored procedure that returns 3 recordsets. In asp to move to the next
recordset I'd just do
<%
set rs = rs.nextrecordset
' display data
set rs = rs.nextrecordset
' display data
'etc

Is there an equivalant to this in asp.net? I can get the first recordset
fine just don't know how to move to the 2nd and 3rd

Cheers,
Jon
 
S

Scott Allen

If you are using a DataReader type object, use the NextResult method.
If you are using Fill on a DataSet, all the resultsets will be filled
into DataTables of the DataSet.

HTH,
 
D

Do Quyet Tien

e.g. recordset1 in ds.Tables[0], recordset2 in ds.Tables[1] and so on...

Tiendq,
(e-mail address removed)
 
J

Jon Spivey

got it - thanks

Jon

Do Quyet Tien said:
e.g. recordset1 in ds.Tables[0], recordset2 in ds.Tables[1] and so on...

Tiendq,
(e-mail address removed)

Scott Allen said:
If you are using a DataReader type object, use the NextResult method.
If you are using Fill on a DataSet, all the resultsets will be filled
into DataTables of the DataSet.

HTH,
have
 

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

Members online

No members online now.

Forum statistics

Threads
473,755
Messages
2,569,537
Members
45,023
Latest member
websitedesig25

Latest Threads

Top