Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2000 Forums
 SQL Server Development (2000)
 More Than one Recordsets

Author  Topic 

jitudavda
Starting Member

11 Posts

Posted - 2001-07-07 : 02:50:06
Hi ALL
I'm Creating one ASP page which requires more than one query to database and even every query is derived from multiple tables.
I'm using six stored procedures for this page. I'm executing all SP in one SP named 'HomePage'. The Code for HomePage is as under :

Create StoredProcedure HomePage
( @MemberID )
AS
--for list of products from 3 tables
Exec MyList @MemberID
--for all the mail subject from one table
Exec MyMails @MemberID
--for all the product names ,query from 3 tables
Exec MyOffers @MemberID
--query from 3 tables and lot of matching process done in this
Exec MyMatch @MemberID
--query from 2 tables
Exec MyAuctions @MemberID
return

I require to execute all the query at one and from db and then display one by one on ASP page. On ASP page I'm useing
Set RS = RS.NextRecordset
for six times at related splace one by one. I've formed HomePage SP as per the required recordsets one by one.
NOW THE PROBLEM IS:
Some time any one of the executed query derives no results. at that time I'm facing a problem of finding which execution has derived no results. It happens like this: I'm using at first position MyList of products. In this if no record derived the recordset referes to the records of MyMails and gives error of [b]wrong ordinal reference[b].

At present I'm executing all six procedure by executing CommandObject Six different times. Can any one suggest ?
Thank you.

Jitu

   

- Advertisement -