请检查以下代码哪里出错了为什么添加不进数据库(数据库是SQL)
<%
jpname=request.form("jpname")
jpjiege=request.form("jpjiege")
jpclass=request.form("jpclass")
jppic=request.form("jppic")
if name<>"" and edit<>"添加" then
sql="select * from jipin"
set rs=server.createobject("adodb.recordset")
rs.open sql,connstr,3,2
rs.addnew
rs("jpname")=jpname
rs("jpjiege")=jpjiege
rs("jpclass")=jpclass
rs("jppic")=jppic
rs.update
session("jpname")=jpname
response.redirect "ok.asp"
end if
dim sql
dim count1
set rs = conn.execute("select * from jipin ORDER BY id desc")
%>