怎样查询 复选框表单 提交上来的值 asp+access...

来源:百度知道 编辑:UC知道 时间:2024/05/19 19:11:51
如题:

表单提交页是个 复选框,
<form method="post" action="处理页">
<input name="qq" type="checkbox" value="4" />
<input name="qq" type="checkbox" value="5" />
<input name="qq" type="checkbox" value="6" />
<input type="submit" value="提交"/>
</form>

在处理页我想查找 id 字段(自动编号主键字段) 为 表单值的记录,,,该怎么写 sql 语句啊? ??

我写的这个为什么报错,说语句未结束

select * from 表名 where [id] in ("&request("qq")&"),conn,1,1

rs.open "select * from 表名 where [id] in ("&request("qq")&")",conn,1,1

最后的,conn之前缺少一个双引号 "

把你这段代码改成下面的就可以了:

select * from 表名 where [id] in ("&request("qq")&")",conn,1,1