能具体点吗?比如:
<%
rq = trim(request("rq"))
fjgs = trim(request("fjgs"))
dh = trim(request("dh"))
zl = trim(request("zl"))
js = trim(request("js"))
emsh = trim(request("emsh"))
je = trim(request("je"))
set rs=server.CreateObject("adodb.recordset")
sql="select * from ems where dh = '"&dh&"'"
rs.open sql,conn,1,3
if rs.recordcount <> 0 then
response.Write "<script >"
response.Write("alert('不能在添加!');")
response.Write("window.history.back();")
response.Write("</script>")
else
rs.addnew
rs("rq") = rq
rs("fjgs") = fjgs
rs("dh") = dh
rs("zl") = zl
rs("js") = js
rs("emsh") = emsh
rs("je") = je
rs.update
response.Write "<script >"
'response.Write("alert(成功!');")
response.Write("window.navigate('ems.asp')")
response.Write("</script>")
end if
rs.close
set rs = nothing
conn.close
set conn = nothing
%>
我又想把相同的信息添加到表ems2去
表ems2里有rq2 fjgs2 dh2 zl2 js2 emsh2 je2
谢谢!!