Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Westi on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

SQL Server and cursors

Status
Not open for further replies.

transparent

Programmer
Sep 15, 2001
333
GB
I keep getting the error: 'Rowset position cannot be restarted '
when executing a stored procedure. However when run using query analyser it returns a row. My asp code reads:

set obj_RSet = server.createobject("ADODB.recordset")

with obj_Comm

.ActiveConnection = obj_Conn
.CommandText = "usp_news_main_by_user_admin"
.CommandType = adCmdStoredProc
.Parameters.Append .CreateParameter("@Page",adInteger,adParamInput,2,int_page)
.Parameters.Append .CreateParameter("@RecsPerPage",adInteger,adParamInput,2,4)
.Parameters.Append .CreateParameter("@user_id",adInteger,adParamInput,2,session("admin_id"))

end with


obj_RSet.open obj_Comm, ,adOpenKeyset

if not obj_RSet.EOF then ........

Any ideas why this is a problem?

Cheers
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top