Hi,
I don't know if anyone can help, but I am having a rather odd problem. I
am using a Sybase (11) database and am able to connect ok and execute a
stored procedure in the database, but when I try to pass a parameter to
the procedure I get the following error :
Microsoft OLE DB Provider for ODBC Drivers (0x80004005)
[INTERSOLV][ODBC SQL Server driver][SQL Server]Procedure sn_test1 expects
parameter @name, which was not supplied.
If I don't try and pass the parameter, I get a "procedure expects the
following parameter(@name) error"
The code I am using is as follows:
<%@ Language=VBScript %>
<%
gsConnect = "Driver={Sybase System
11};SRVR=ISSERVER;UID=DB_USER2;PWD=intershop;"
Set Conn = server.createobject("ADODB.Connection")
Conn.open gsConnect
Set RS = server.CreateObject("ADODB.recordset")
Set CmdCommand = server.CreateObject("ADODB.command")
With CmdCommand
.ActiveConnection = Conn
.CommandType = 4
.CommandText = "sn_test1"
' .Parameters("@name") = "hello"
Set RS = .Execute
end with
if not RS.EOF then
while not rs.eof
Response.Write("<br>Position : " & rs.fields("Name1"))
rs.MoveNext
wend
else
Response.Write(gsConnect)
Response.Write("<br>Oh No")
end if
Conn.Close
Set Conn = Nothing
%>
Would be grateful for any advice
thanks
Stewart