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.
| Author |
Topic |
|
Nitu
Yak Posting Veteran
81 Posts |
Posted - 2006-04-13 : 10:36:11
|
| I am getting this error:ADODB.Recordset error '800a0cc1' Item cannot be found in the collection corresponding to the requested name or ordinal. when i run this following code:-------------------------------------stored procedure------------------------------------ create spupdaterecords@input1 intasDeclare @errormessage nvarchar(50)Declare @tabcount intDeclare @tabcount1 intset @errormessage = ''if @input = 1beginupdate table set field = -1delete table1 where field = 1endselect @tabcount = count(*) from table1select @tabcount1 = count(*) from tableif @tabcount <> @tabcount1 Set @errormessage = 'failed'else Set @errormessage = 'successful'select @errormessage as errormessage Go------------------------------------------------asp------------------------------------------------set rs = createobject("adodb.recordset")sql = "spupdaterecords 1"rs.open sql, connresponse.write rs("errormessage")Can someone please tell me where iam wrong.Thanks in advance,Nitu |
|
|
Srinika
Master Smack Fu Yak Hacker
1378 Posts |
Posted - 2006-04-13 : 10:44:24
|
| [code]create spupdaterecords@input1 intasDeclare @errormessage nvarchar(50)Declare @tabcount intDeclare @tabcount1 intset @errormessage = ''if @input = 1[/code]Check the Parameter NameSrinika |
 |
|
|
jen
Master Smack Fu Yak Hacker
4110 Posts |
Posted - 2006-04-13 : 22:48:44
|
if you're going to do it that way in your sp,use rs.fields(0) insteadquote: response.write rs("errormessage")
--------------------keeping it simple... |
 |
|
|
|
|
|