asp 参数问题

来源:百度知道 编辑:UC知道 时间:2024/05/21 19:48:25
错误类型:
Microsoft JET Database Engine (0x80040E10)
至少一个参数没有被指定值。
/search.asp, 第 7 行

代码如下:
dim bh
bh=request.form("cipai")
cx="select * from shici where cipai=" + bh
set rs = server.createobject ("adodb.recordset")
rs.open cx,conn,1,1
表单中的参数已经传到.估计是SQL语句的参数没传到..怎么解决啊

cx="select * from shici where cipai=" ' &bh& ' "

在这句后面加上
cx="select * from shici where cipai=" + bh
resopnse.write cx
你测一下就知道bh倒底有没有传过来,我估计没有。呵。