提交后怎样提取ID
<%title=request.form("title")
content=request.form("content")
dateandtime=date()
if title="" then
FoundErr=True
ErrMsg=ErrMsg & "<br><li>新闻标题不能为空!</li>"
end if
if content="" then
FoundErr=True
ErrMsg=ErrMsg & "<br><li>新闻内容不能为空!</li>"
end if
if FoundErr<>True then
set rs=server.CreateObject("ADODB.RecordSet")
sql = "SELECT * FROM news"
rs.Open sql,Conn,2,3
rs.addnew
rs("title") = title
rs("content") = content
rs("dateandtime")=dateandtime
rs.update
rs.close
set rs = nothing
Response.Redirect "Id是数据库自动编号的,怎样才能在提交后就知道此段数据的ID号呢?望高手赐教"
else
call WriteErrMsg()
end if