Guys for MONTHS now MONTHS ive been trying to call MSSQL Stored procedures with my Webserver and i cannot accomplish this...I am running Windows 2000 Advance Server SP2....If i place this same ASP Page on my NT4 Server box it works fine any ideas???!?! I am so lost and furious about the while situation....I reinstalled the whole OS, Reapplied MDAC it still fails...Here is a copy of my SP and ASP call anyone see anything wrong??
Stored Procedure
-----------------------------------
ALTER PROCEDURE LISTCONBYLOC @LocId int,@LocationName as varchar(200) output AS
select * from consultants where approved=1 and city=@LocId
SELECT @LocationName = (SELECT CITY FROM CITIES WHERE [ID]=@LocId)
GO
ASP Page Call
------------------------------------
LocId=64
Set oCommand = Server.Createobject("Adodb.Command"
oCommand.ActiveConnection=oConn
oCommand.CommandType=adCmdStoredProc
'oCommand.CommandText = "LISTCONBYLOC"
Set param = oCommand.CreateParameter("@LocId", AdInteger, adParamInput, 15, LocId)
oCommand.Parameters.Append(param)
Set param = oCommand.CreateParameter("@LocationName", AdVarchar, adParamOutput, 200, ""
oCommand("@LocId"
= LocId
oCommand("@LocationName"
= "s"
set rsConsultants = oCommand.Execute()
(Keep in mind i tried diffrent ways of calling this procedure also, I read 3 diffrent ways on the MS website area)
Here is the error i recieve....
Syntax error or access violation
/ConsultantsByLoc.asp, line 19
Line 19 is the .Execute line.
Also when i run this procedure via Query Analyzer i get back 2 rows of data.
Thanking you in advance,
Gordon
PLEASEEEEE HELPPPPP!!!!!! :0)
Gordon R. Durgha
gd@vslink.net
Stored Procedure
-----------------------------------
ALTER PROCEDURE LISTCONBYLOC @LocId int,@LocationName as varchar(200) output AS
select * from consultants where approved=1 and city=@LocId
SELECT @LocationName = (SELECT CITY FROM CITIES WHERE [ID]=@LocId)
GO
ASP Page Call
------------------------------------
LocId=64
Set oCommand = Server.Createobject("Adodb.Command"
oCommand.ActiveConnection=oConn
oCommand.CommandType=adCmdStoredProc
'oCommand.CommandText = "LISTCONBYLOC"
Set param = oCommand.CreateParameter("@LocId", AdInteger, adParamInput, 15, LocId)
oCommand.Parameters.Append(param)
Set param = oCommand.CreateParameter("@LocationName", AdVarchar, adParamOutput, 200, ""
oCommand("@LocId"
oCommand("@LocationName"
set rsConsultants = oCommand.Execute()
(Keep in mind i tried diffrent ways of calling this procedure also, I read 3 diffrent ways on the MS website area)
Here is the error i recieve....
Syntax error or access violation
/ConsultantsByLoc.asp, line 19
Line 19 is the .Execute line.
Also when i run this procedure via Query Analyzer i get back 2 rows of data.
Thanking you in advance,
Gordon
PLEASEEEEE HELPPPPP!!!!!! :0)
Gordon R. Durgha
gd@vslink.net