p2p.wrox.com Forums

Need to download code?

View our list of code downloads.


  Return to Index  

asp_databases thread: ADODB.Recordset error '800a0e78'


Message #1 by "Stef" <sne@s...> on Thu, 7 Dec 2000 16:28:00 -0000
Hello,



I receive this error when I try to use a store procedure in my DB in

Sybase server

I anderstand what this meen, but I don't know why ?



I create a connection via a DSN, after that I try to execute my sql; when

I try my query directly on my server, the procedure runs well !



Here is my code



Dim  mutaconn,mutaresult

	

	GetConn mutaconn

	sqlquery="exec sp_muta " &_      

            "  @language = " & sqlEncode(road65_language) &_

            ", @house_no = " & road65_house_number &_

            ", @street_id = " & road65_street_id &_

            ", @street_remainder = " & sqlEncode(road65_rebuild) &_

            ", @name_hash = ''" &_

       	    ", @chrname_hash = ''" &_

            ", @birthdate = " & sqlEncode(road65_birthdate) &_

            ", @message = ''" &_

            ", @db_name = 'http'" &_

            ", @suser_name = 'intranet'"  &_

            ", @powerbuilder = 'Y'" &_

            ", @name = " & sqlEncode(road65_name) &_

            ", @chrname = " & sqlEncode(road65_chrname) 

			

			'rw(sqlquery)

			

	set mutaresult = mutaconn.execute(sqlquery)

	if mutaresult.EOF AND mutaresult.BOF then

		rw("<CENTER><H3> Sorry, No result ! </H3></CENTER>")

		mutanewreturnstatus   = -1

	else



.....

sqlEncode is just a function to put ' in the right place



Can somebody help me ?

Thanks



Stef.

Message #2 by "Li, Fang" <fang@c...> on Thu, 7 Dec 2000 12:12:37 -0500
two example in a wrox's book:

database: SQL Server.



<one>

Set objRs = Server.CreateObject("ADODB.Recordset") 

strSQL = "qparmBoats '" & CStr(strBoat) & "'" 

objRs.Open strSQL, objConn, adOpenForwardOnly, , adCmdStoredProc 



<two>

Set objCmd = Server.CreateObject("ADODB.Command") 

Set objCmd.ActiveConnection = objConn 

objCmd.CommandText = "{call dbo.up_parmins_boatclass ('" & CStr(strClass) &

_ 

 "'," & CLng(lngLength) & "," & CLng(lngWeight) & _ 

 "," & CLng(lngMainJib) & "," & CLng(lngSpinnaker) & _ 

 ",'" & CStr(strAuthority) & "')}" 

objCmd.CommandType = adCmdText 

objCmd.Execute 





-----Original Message-----

From: Stef [mailto:sne@s...]

Sent: Thursday, December 07, 2000 11:28 AM

To: ASP Databases

Subject: [asp_databases] ADODB.Recordset error '800a0e78'





Hello,



I receive this error when I try to use a store procedure in my DB in

Sybase server

I anderstand what this meen, but I don't know why ?



I create a connection via a DSN, after that I try to execute my sql; when

I try my query directly on my server, the procedure runs well !



Here is my code



Dim  mutaconn,mutaresult

	

	GetConn mutaconn

	sqlquery="exec sp_muta " &_      

            "  @language = " & sqlEncode(road65_language) &_

            ", @house_no = " & road65_house_number &_

            ", @street_id = " & road65_street_id &_

            ", @street_remainder = " & sqlEncode(road65_rebuild) &_

            ", @name_hash = ''" &_

       	    ", @chrname_hash = ''" &_

            ", @birthdate = " & sqlEncode(road65_birthdate) &_

            ", @message = ''" &_

            ", @db_name = 'http'" &_

            ", @suser_name = 'intranet'"  &_

            ", @powerbuilder = 'Y'" &_

            ", @name = " & sqlEncode(road65_name) &_

            ", @chrname = " & sqlEncode(road65_chrname) 

			

			'rw(sqlquery)

			

	set mutaresult = mutaconn.execute(sqlquery)

	if mutaresult.EOF AND mutaresult.BOF then

		rw("<CENTER><H3> Sorry, No result ! </H3></CENTER>")

		mutanewreturnstatus   = -1

	else



.....

sqlEncode is just a function to put ' in the right place



Can somebody help me ?

Thanks



Stef.




  Return to Index