为什么execute语句不会执行
添加的语句不能执行,但换了删除的却可以不知道怎么回事
if check="add" then
username=trim(request("username"))
password=trim(request("password"))
if username="" or password="" then
Response.Write ("<script>alert('请填写管理员名和密码!');javascript:history.back(0)</script>")
response.end
end if
conn.execute("insert into rsadmin(username,password)values('"&username&"','"&password&"')")
conn.close
Response.Write ("<script>alert('管理员已添加!');window.location='admin.asp'</script>")
response.end
end if
删除语句:
if check="delete" then
id=request("id")
username=trim(request("username"))
password=trim(request("password"))
sql="delete from rsadmin where id="&id
conn.Execute(sql)
conn.close
response.Redirect "admin_user.asp"
response.end
end if