ASP删除内容时发生错误

来源:百度知道 编辑:UC知道 时间:2024/06/04 05:05:07
Microsoft JET Database Engine 错误 '80040e14'

语法错误 (操作符丢失) 在查询表达式 'id=' 中。

/2/students.asp,行 162

code:

<%
if request("action")="del" then
set rs=server.CreateObject("adodb.recordset")
n=request.form("id")
conn.execute ("delete from students where id="&id)
rs.Close
set rs=nothing
end if
%>

这是你操作错误
set rs=server.CreateObject("adodb.recordset")
n=request.form("id")
conn.execute ("delete from students where id="&id)
rs.Close
set rs=nothing
是删除错误
只要将系统垃圾清除即可