ASP中调用存储过程问题 10
<%dimConn,strSQL,rs,StorageIDStorageID=0101setConn=Server.CreateObject("ADODB.Connect...
<%
dim Conn, strSQL, rs, StorageID
StorageID = 0101
set Conn = Server.CreateObject("ADODB.Connection")
SqlString = "GetDate()"
SqlDatabaseName = "HLJXC" '数据库名
SqlPassword = "" '用户密码
SqlUsername = "sa" '用户名
SqlLocalName = "(local)" '连接名(本地用local,外地用IP)
ConnStr = "Provider = Sqloledb; User ID = " & SqlUsername & "; Password = " & SqlPassword & "; Initial Catalog = " & SqlDatabaseName & "; Data Source = " & SqlLocalName & ";"
Conn.Open connstr
strSQL = "offhandstock " & StorageID
Set rs = Conn.Execute(strSQL)
%>
第一次在ASP中调用存储过程
提示错误
错误类型:
Microsoft OLE DB Provider for SQL Server (0x80040E10)
过程 'OffhandStock' 需要参数 '@StorageID',但未提供该参数。
/ck/index.asp, 第 28 行
请问是哪里不对?
OffhandStock是存储过程的名字 展开
dim Conn, strSQL, rs, StorageID
StorageID = 0101
set Conn = Server.CreateObject("ADODB.Connection")
SqlString = "GetDate()"
SqlDatabaseName = "HLJXC" '数据库名
SqlPassword = "" '用户密码
SqlUsername = "sa" '用户名
SqlLocalName = "(local)" '连接名(本地用local,外地用IP)
ConnStr = "Provider = Sqloledb; User ID = " & SqlUsername & "; Password = " & SqlPassword & "; Initial Catalog = " & SqlDatabaseName & "; Data Source = " & SqlLocalName & ";"
Conn.Open connstr
strSQL = "offhandstock " & StorageID
Set rs = Conn.Execute(strSQL)
%>
第一次在ASP中调用存储过程
提示错误
错误类型:
Microsoft OLE DB Provider for SQL Server (0x80040E10)
过程 'OffhandStock' 需要参数 '@StorageID',但未提供该参数。
/ck/index.asp, 第 28 行
请问是哪里不对?
OffhandStock是存储过程的名字 展开
1个回答
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询